Vowel-consonant metathesis is observed in a variety of contexts throughout the Nivaĉle (Mataguayan) grammar. It occurs in both verbal and nominal domains, characteristically resulting from the affixation of a consonant-initial suffix to a consonant-final stem. This paper provides an optimality theoretic account for vowel-consonant metathesis and vowel epenthesis in Nivaĉle. It is demonstrated that metathesis responds to phonological requirements; specifically, it serves to avoid marked structures in the language: complex codas, derived complex onsets, and bad syllable contacts. The prosodic analysis of syllable structure constraints aims to provide broad empirical coverage, as well as a coherent and integrated theoretical interpretation.