Home
CSS
RWD Images
Tryit: Background image and background-size: 100% 100%
Run ❯
Get your
own
website
Result Size:
625 x 534
×
Change Orientation
Save Code
Change Theme, Dark/Light
Go to Spaces
<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <style> div { width: 100%; height: 400px; background-image: url('img_flowers.jpg'); background-size: 100% 100%; border: 1px solid red; } </style> </head> <body> <p>Resize the browser window to see the effect.</p> <div></div> </body> </html>