Title: Custom CSS variables
Last modified: August 31, 2016

---

# Custom CSS variables

 *  [Peter Munton](https://wordpress.org/support/users/petermunton/)
 * (@petermunton)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/custom-css-variables/)
 * Hi I have looked everywhere and have not found any reference to my needs.
 * I use custom css for a page on my site But the code has many occouances that 
   need the same setting eg the colour of text, the width of the shadow in “Text
   shadow” etc on the custom css page is it possible to set varibles,for example
   
   Text Size = 36px Text colour = #000 shadow size = -2 Shadow colour = #fff
 * then all instances where I want the font colour to be #000 i would insert “text
   colout”
 * Therefor if I need to change the colour of that text I only need to change the
   variable.
 * I hope I am making sense

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Geoffrey Shilling](https://wordpress.org/support/users/geoffreyshilling/)
 * (@geoffreyshilling)
 * Volunteer Moderator
 * [10 years, 1 month ago](https://wordpress.org/support/topic/custom-css-variables/#post-7264073)
 * You are making perfect sense. Unfortunately that is not permitted in standard
   CSS. Depending on how comfortable you are with learning new things, this _is_
   possible using a CSS pre-processor such as [SASS](http://sass-lang.com/) or [Less](http://lesscss.org/).
 *  Thread Starter [Peter Munton](https://wordpress.org/support/users/petermunton/)
 * (@petermunton)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/custom-css-variables/#post-7264091)
 * Thank you for your prompt reply Geoffrey. I know nothing of SASS or Less and 
   therfore fear them. I really want to restrict my code to the particular page,
   and not affect the rest of the site. I fear upsetting other pages.
    I will take
   a look and see what they are about. Do you think there may be a chance of this
   functionality b eing wriyyen into CSS.
 *  [Geoffrey Shilling](https://wordpress.org/support/users/geoffreyshilling/)
 * (@geoffreyshilling)
 * Volunteer Moderator
 * [10 years, 1 month ago](https://wordpress.org/support/topic/custom-css-variables/#post-7264203)
 * You’re welcome. It can be intimidating at first, but if you work with CSS much
   and this is something you would be interested in, you could always focus _only_
   on the variables (color names); ignore the rest of SASS/Less altogether. When
   I was working on front-end development, I had just started to look into those–
   and mostly for the variables.
 * I don’t know too much about it being included in CSS, but I haven’t looked, either.
   It was in an experimental phase the last I knew. At the rate major changes to
   CSS and HTML happen, it could be quite a while before there is any standard. 
   Again, that is just based on my limited knowledge of what they are currently 
   working on.
 * Good luck!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Custom CSS variables’ is closed to new replies.

## Tags

 * [css](https://wordpress.org/support/topic-tag/css/)
 * [variables](https://wordpress.org/support/topic-tag/variables/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [Geoffrey Shilling](https://wordpress.org/support/users/geoffreyshilling/)
 * Last activity: [10 years, 1 month ago](https://wordpress.org/support/topic/custom-css-variables/#post-7264203)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
