Answers for "how to center a page css"

CSS
3

css center div in page

.center {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }
Posted by: Guest on July-02-2021
2

center on page css

body {
  display: grid;
  place-items: center;
  height: 100vh;
  margin: 0;
}
Posted by: Guest on June-01-2021
0

html center body

body {
  display:flex; flex-direction:column; justify-content:center;
  min-height:100vh;
}
Posted by: Guest on July-28-2020

Code answers related to "how to center a page css"

Browse Popular Code Answers by Language