Can't Get Blog Title(s) to Change Color

  • Author
  • #1098039


    I just started messing around with CSS today, and I was able to make changes to pretty much everything I wanted to except the title of my blog. I’ve tried a few different ways. This is the code that I’m trying to make work:

    body {
    color: darkblue;
    // blog title
    title {
    color: blue!important;
    // blog post titles
    h2 {
    color: blue!important;

    The body text color changes to navy blue, but the h2 and title won’t change. Any idea why?

    Thanks in advance,

    The blog I need help with is


    Hey scottieenriquez
    This forum is only for the WordPress hoisted blogs/sites. For personal/self hoisted one’s, here’s the forum link .
    Best wishes for your site :)


    It is a WordPress hosted site. I just use my own domain.


    Actually WordPress hoisted and self hoisted meaning,
    This link would help you to know!


    And about your issue,
    To change the color of your blog post title’s
    modify the code as,
    h2 a{
    color:blue !important;

    For blog title you could go for,
    #logo a{
    color: blue !important;

    And body color change I guess it worked for you right?

    #1098452 is indeed setup here at @castelinokelvin, a quick check of the footer link will usually give you the right info about that.

    Regarding CSS not working when you think it should, I would recommend checking it using your browser’s web inspector. If you right-click on an element and select “Inspect Element,” then you should see a panel open with the HTML for what you clicked on as well as all of the CSS that applies to it. You can usually check or uncheck different pieces to turn them on or off to see what’s doing what. It’s a really nice way to learn about the CSS of a site.

    CSS has all of these specificity rules. The most specific selector wins, or if there is more than one rule using selectors with the same specificity, then whatever is loaded last wins. In your case, just using the selector “h2” is not enough in the Oxygen theme because that theme uses a selector that is more specific: “.entry-title a”

    Here is an example you can try out. The top one is for the main site title (or what I would think of as the blog title), and the bottom rule is for post titles. You’ll notice there are two because on the home page or archives pages the post titles are links (so you need to add “a” to the selector) and the individual posts just use “.entry-title”. I added “#page” to the selectors to make them even more specific so they will override other stuff in the theme:

    #page .site-title a {
    	color: #f00;
    #page .entry-title,
    #page .entry-title a {
    	color: #0f0;

The topic ‘Can't Get Blog Title(s) to Change Color’ is closed to new replies.