---
title: "Is CSS case sensitive?"  
description: "Is CSS case sensitive?"  
author: "Anonymous User"  
published: 2012-12-13  
updated: 2012-12-13  
canonical: https://www.mindstick.com/forum/498/is-css-case-sensitive  
category: "css-css3"  
tags: ["css-css3"]  
reading_time: 1 minute  

---

# Is CSS case sensitive?

Hi every one \
\
Can any one tell me, [CSS](https://www.mindstick.com/forum/514/background-gradient-ie7-css-problem) is [case sensitive](https://www.mindstick.com/interview/19/is-xml-case-sensitive)?\
\
Thanks in advance.

## Replies

### Reply by AVADHESH PATEL

Hello Jayprakash sharma\
\
Cascading Style Sheets (CSS) is not case [sensitive](https://answers.mindstick.com/qa/34778/recently-heard-about-ultra-sensitive-electronic-skins-what-is-it). However, font families, URLs to images, and other direct references with the style sheet may be. The trick is that if you write a document using an XML declaration and an XHTML doctype, then the CSS class names will be case sensitive for some browsers. It is a good idea to avoid naming classes where the only difference is the case, for example: div.myclass { ...} div.myClass { ... } If the DOCTYPE or XML declaration is ever removed from your pages, even by mistake, the last instance of the style will be used, regardless of case. \
\
I hope it remove your doubts.


---

Original Source: https://www.mindstick.com/forum/498/is-css-case-sensitive

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
