Title: HTML code for colored link
Last modified: December 6, 2022

---

# HTML code for colored link

 *  [rajeevbagra2025](https://wordpress.org/support/users/rajeevbagra2025/)
 * (@rajeevbagra2025)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/html-code-for-colored-link/)
 * Here is the HTML code that I have pasted on the footer of the website:
 * `An initiative by [Techcosec Limited](https://techcosec.co.uk) in association
   with [Digital Splendid OPC Pvt. Ltd.](https://digitalsplendid.agency)
 * ([https://www.canva.com/design/DAFT-7rX7wI/fcJhgV15hCQLhuCG78bxQQ/view?utm_content=DAFT-7rX7wI&utm_campaign=designshare&utm_medium=link2&utm_source=sharebutton](https://www.canva.com/design/DAFT-7rX7wI/fcJhgV15hCQLhuCG78bxQQ/view?utm_content=DAFT-7rX7wI&utm_campaign=designshare&utm_medium=link2&utm_source=sharebutton))
 * It will help if links are colored differently.
 * I came across this source: [https://www.w3schools.com/html/html_links_colors.asp](https://www.w3schools.com/html/html_links_colors.asp)
 * Is there a way that code Example be added to my code.
    -  This topic was modified 3 years, 6 months ago by [rajeevbagra2025](https://wordpress.org/support/users/rajeevbagra2025/).
    -  This topic was modified 3 years, 6 months ago by [rajeevbagra2025](https://wordpress.org/support/users/rajeevbagra2025/).
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fhtml-code-for-colored-link%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  [mrtom414](https://wordpress.org/support/users/mrtom414/)
 * (@mrtom414)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/html-code-for-colored-link/#post-16264789)
 * You can add custom CSS to any project. If it an older theme you can just go to
   the customizer and add it to the custom CSS section. You can also create a small
   plugin to enqueue the style sheet. The plugin would have the advantage of being
   moved from theme to theme. The custom CSS is only valid in the theme you use 
   it in. You can also added it in the style.css file. But, You take a risk of having
   this file overwritten if the theme updates.
 * If it a newer theme that uses FSE it a little more difficult because custom CSS
   has been turned off. You could add it in the style.css sheet but again it might
   get overwritten. You could also create your own CSS file and add it in with a
   plugin. You could also add block level styles in the theme.json file. I would
   avoid modifying the theme unless it a child theme.
 *  [Marklcm](https://wordpress.org/support/users/marklcm/)
 * (@marklcm)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/html-code-for-colored-link/#post-16265004)
 *     ```
       .site-footer div.wrap p a:nth-child(2) {
         color: red;
       }
   
       .site-footer div.wrap p a:nth-child(1) {
         color: green;
       }
       ```
   
 * use a plugin such as [https://wordpress.org/plugins/simple-custom-css/](https://wordpress.org/plugins/simple-custom-css/)
   to add the css to your site.
    The link to w3schools shows how to enable different
   colors for different pseudo-elements such as hover etc. I think you are asking
   to change the color of each link itself. The code above targets the first and
   second linksin the (nth-child) site-footer links
    -  This reply was modified 3 years, 6 months ago by [Marklcm](https://wordpress.org/support/users/marklcm/).

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

The topic ‘HTML code for colored link’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 3 participants
 * Last reply from: [Marklcm](https://wordpress.org/support/users/marklcm/)
 * Last activity: [3 years, 6 months ago](https://wordpress.org/support/topic/html-code-for-colored-link/#post-16265004)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
