Change the font size of a button with CSS

To change the font size of a button, use the font-size property.

You can try to run the following code to change the font size


Live Demo

<!DOCTYPE html>
         .button {
            background-color: yellow;
            color: black;
            text-align: center;
            font-size: 15px;
      <p>Click below for result:</p>
      <button class = "button">Result</button>

Updated on: 24-Jun-2020

15K+ Views

Kickstart Your Career

Get certified by completing the course

Get Started