---
# System prepended metadata

title: what is DOM

---

# what is DOM

When you write HTML and view it in the browser, the browser turns your HTML into something that is called the Document Object Model or the DOM.

The DOM is represented in a tree that looks very much like HTML.

basically dom is is tree
html
head
    have links, meta, title...
body
    have div ,span,p tag and other nested roots
    

The document is responsible for everything from the opening HTML tag <html>, the doctype as well, to the closing HTML tag(</html>).