← All gradients
35%How it works
UI

Login Background

#0F172A
#1E1B4B
#312E81
Text readability
Ui DarkCool

Login Background is a dark and cool 3-colour linear gradient that runs from near-black (#0F172A) through deep blue (#1E1B4B) to blue (#312E81) at 135°. It suits dark-mode interfaces and footers and dashboards and SaaS landing pages. White text reads best on it, at a contrast ratio of 15.1:1 against the gradient’s average colour (AAA). Check every point, not just the average →

CSS
background: linear-gradient(135deg, #0F172A, #1E1B4B, #312E81);
Tailwind
bg-gradient-to-br from-[#0F172A] via-[#1E1B4B] to-[#312E81]
Figma token
{
    "login-background": {
        "value": "linear-gradient(135deg, #0F172A 0%, #1E1B4B 50%, #312E81 100%)",
        "type": "color"
    }
}

Login Background gradient for SwiftUI, Flutter, Android and more

The same gradient, same direction, ready for your app or design system.

let loginBackgroundGradient = LinearGradient(
    colors: [
        Color(red: 0.059, green: 0.09, blue: 0.165),
        Color(red: 0.118, green: 0.106, blue: 0.294),
        Color(red: 0.192, green: 0.18, blue: 0.506)
    ],
    startPoint: UnitPoint(x: 0, y: 0),
    endPoint: UnitPoint(x: 1, y: 1)
)

// Usage
Rectangle().fill(loginBackgroundGradient)

Colours in the Login Background gradient

StopNameHEXRGBHSL
1Near-black#0F172Argb(15, 23, 42)hsl(222, 47%, 11%)
2Deep blue#1E1B4Brgb(30, 27, 75)hsl(244, 47%, 20%)
3Blue#312E81rgb(49, 46, 129)hsl(242, 47%, 34%)

Login Background gradient in use

Build something beautifulA hero section on the Login Background gradientGet started
Button
Card accentAs a border or progress bar
Gradient text

Login Background gradient variations

Reversed
Horizontal
Radial
Conic
Softer
Deeper
Smooth (OKLCH)
Hard stops

Download as an image

Free PNG wallpapers and backgrounds, drawn in your browser at full resolution.

Frequently asked questions

What are the hex codes for the Login Background gradient?

The Login Background gradient uses 3 colours: #0F172A, #1E1B4B and #312E81, at an angle of 135°.

How do I use the Login Background gradient in CSS?

Paste background: linear-gradient(135deg, #0F172A, #1E1B4B, #312E81); into any element’s styles. For Tailwind, use the class list in the Tailwind block above.

What text colour works on the Login Background gradient?

White text has the best contrast, at 15.1:1 against the gradient’s average colour, which is AAA. Check the lightest and darkest ends too if text spans the whole gradient.