Skip to main content

Changing the background colour of a link (button)

Updated over 3 months ago

Now we're going to look at how to changethe background colour of this button.

Here's the button code:

<a href="url" style="display: block; margin: 20px auto; width: 250px; text-align: center; font-family: arial; background: red; padding: 20px; line-height: 20px; color: #fff; text-decoration: none; font-weight: bold;">Our POST-COVID rules</a>

In this code, you need to change the colour selected in red to the colour you want.

You can either use another colour in English (pink , yellow , red ...), or use exactly the colour code you want (#782e2f , #000 , #5293C7 ...).

Did this answer your question?