Styling ASP.NET MVC validation errors?

It sounds like what you are doing is correct, but the css gets cached which means you won't necessarilly see the changes you make.

Once you have edited the css file, press Ctrl + F5 from your browser to reload css.


If you style up .field-validation-error then this will change the validation error text messages.

.field-validation-error{ color: red; font-weight: bold; }

If you style up .input-validation-error then this will change the input style when there is a validation error.

.input-validation-error{ background: pink; border: 1px solid red; }