Set viewport

Usually portable device such us mobile phones and tablets has a small screen, so during navigation mobile browser scales the website and fits it to screen.

Viewport is a HTML meta tag created to control layout on mobile browsers. Here is a simple example of viewport meta tag:
<meta name="viewport" content="width=device-width, initial-scale=1.0">

You should include the viewport declaration into <head> tag in the HTML.
<head>
...
<meta name="viewport" content="width=device-width, initial-scale=1.0">
....
</head>

It has several properties:

  • Width
  • Height
  • Initial Scale
  • Minimum Scale
  • Maximum Scale
Type: 
Is required: 
Required