Blue gradients

Blue gradients are among the most used gradients on the web, from app backgrounds and hero sections to buttons and charts. Blue feels calm and trustworthy, and a gradient adds depth without adding noise. The gradients below cover deep navy and royal blends that carry white text comfortably, ocean and sky gradients in the middle, and pale pastel blues that need dark text. Pairing two neighboring blues gives a smooth, professional look, while running blue into purple or cyan adds more energy. Each gradient shows its CSS, ready to paste, plus the text color that reads best across it and its worst-case contrast. Open any of them in the gradient generator to change the stops or angle.

6 blue gradients with CSS code

  • Deep Ocean

    background: linear-gradient(135deg, #000080 0%, #4169E1 100%);

    White text passes AA, at worst 4.84:1.

  • Clear Sky

    background: linear-gradient(180deg, #87CEEB 0%, #E0F2FF 100%);

    Black text passes AA, at worst 12.05:1.

  • Royal Wave

    background: linear-gradient(120deg, #1E3A8A 0%, #2563EB 50%, #60A5FA 100%);

    White text fails AA somewhere, at worst 2.54:1.

  • Midnight

    background: linear-gradient(160deg, #0E1424 0%, #2C3654 100%);

    White text passes AA, at worst 11.91:1.

  • Cornflower Haze

    background: linear-gradient(135deg, #6495ED 0%, #CCCCFF 100%);

    Black text passes AA, at worst 7.06:1.

  • Electric Blue

    background: linear-gradient(90deg, #0F48FF 0%, #00BFFF 100%);

    Black text AA large text only, at worst 3.39:1.