# Dash background image

**URL:** <https://community.plotly.com/t/dash-background-image/19578>\
**Category:** Dash Python\
**Created:** [February 14, 2019, 1:26pm UTC](https://community.plotly.com/t/dash-background-image/19578 "2019-02-14T13:26:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Saitharun9](https://avatars.discourse-cdn.com/v4/letter/s/a87d85/32.png) [@Saitharun9](https://community.plotly.com/u/Saitharun9)\
**Post date:** [February 14, 2019, 1:26pm UTC](https://community.plotly.com/t/dash-background-image/19578/1 "2019-02-14T13:26:58Z")

</div>

Hi All,

i am currently using this code to have background image but the output is comming wrong i dont get full image as background as in pic uploaded u can see white space below.tried the same with backgroundcolor but its the same issue.

app.layout = html.Div([  
dcc.Location(id=‘url’,refresh=False),  
html.Div(id=‘intermediate-div’,style={‘display’:“none”}),  
html.Div(id=‘custom-auth-frame’),

```
    ],style={"background-image": 'url("/assets/Background.PNG")'})

```

Any help i can get??.

 ![image](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/2/2d415769285b90729a24527f718e341e4e6c9839.png)

---

<div class="post-metadata">

**Author:** ![caiyij](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/caiyij/32/4462_2.png) [@caiyij](https://community.plotly.com/u/caiyij)\
**Post date:** [February 15, 2019, 9:09pm UTC](https://community.plotly.com/t/dash-background-image/19578/2 "2019-02-15T21:09:33Z")

</div>

If you are using .css file you can set the background like this to ensure if covers entirely:

```auto
html {
  height: 100%;
  ... }
body{
  height:100%;
  background-image: url("/assets/Background.PNG");
  background-size: cover;
  background-position: center;
  ...}

```

---

<div class="post-metadata">

**Author:** ![Saitharun9](https://avatars.discourse-cdn.com/v4/letter/s/a87d85/32.png) [@Saitharun9](https://community.plotly.com/u/Saitharun9)\
**Post date:** [March 7, 2019, 6:36am UTC](https://community.plotly.com/t/dash-background-image/19578/3 "2019-03-07T06:36:20Z")

</div>

Hi caiyij i am using codepen and its not working.
