# Download HTML from a website

> Download a website’s HTML: save the page, view its source, copy the rendered HTML from DevTools, or get HTML, CSS and images in one ZIP. What you can’t get.

Canonical page: https://sitepeel.dev/guides/download-html-from-website/

To download the HTML of a website, press Ctrl+S (Cmd+S on a Mac) and save it as Webpage, HTML only, or press Ctrl+U to view the source and save that. For sites built by scripts, copy the rendered HTML from DevTools, or paste the link into a free Website to HTML tool.

Published: 2026-11-04

Tool used in this guide: [Website cloner](https://sitepeel.dev/website-cloner/index.md)

Free website tool for this task: [Website to HTML](https://sitepeel.dev/free-tools/website-to-html/index.md) (https://sitepeel.dev/free-tools/website-to-html/)

## In short

- View source shows the HTML the server sent, before scripts run
- Many sites build the page with scripts, so their source is almost empty
- DevTools and Website to HTML give the page as it rendered
- Server code, databases and private files never reach your browser

## How to use it

1. **Save the page** Press Ctrl+S (Cmd+S on a Mac) and choose Webpage, HTML only, or Complete to keep its images.
2. **Or view the source** Press Ctrl+U (Cmd+Option+U on a Mac), then save it with Ctrl+S.
3. **Copy the rendered HTML** Open DevTools, right-click the `<html>` tag in Elements and choose Copy > Copy outerHTML.
4. **Or use Website to HTML** Paste the link into the free tool to get the HTML, one CSS file and the images in a ZIP.

## Source HTML or rendered HTML?

Ways to get a website’s HTML, and what each gives you

| Way | What you get | Good for |
| --- | --- | --- |
| View source (Ctrl+U) | The HTML the server sent, before scripts run | Meta tags, links and what loads first |
| Save page as | An HTML file, plus a folder of files with Complete | A quick offline copy |
| DevTools > Copy outerHTML | The page as it is now, after scripts ran | Sites built with React, Vue and other frameworks |
| Website to HTML | Rendered HTML without scripts, one CSS file and the images, in a ZIP | A copy that opens and looks right on your computer |

Good to know: If view source shows little more than `<div id="root"></div>`, scripts build the page. Use the rendered HTML.

## Download the CSS and JavaScript too

- Open DevTools, go to Sources and expand the site’s folder to see every file it loaded.
- Right-click a file and choose Save as, or open it in a new tab and save it.
- In Network, filter by CSS or JS and reload to list each stylesheet and script.
- Most files are minified. Press the `{}` button in Sources to make them readable.

- [Download a website’s CSS](https://sitepeel.dev/guides/download-css-from-website/index.md)

## Save the HTML with a command

curl and wget fetch the HTML the server sends, the same as view source. They don’t run scripts, so script-built pages come back nearly empty.

Example: save-html.sh

```
curl -L https://example.com -o page.html

# with its images and styles, links rewritten
wget --page-requisites --convert-links https://example.com/
```

## What you can’t download

- Server code like PHP, Node or Python: only its output reaches the browser.
- Databases, API keys and private files.
- The original project, like React components: you get the built output.
- Pages behind a login, unless you save them from your own signed-in browser.

Good to know: The site’s text, images and design belong to its owner. Use a copy to learn, and replace them before you publish.

- [What you can and can’t clone from a website](https://sitepeel.dev/guides/can-you-clone-website-backend/index.md)

## Questions and answers

### How do I download the HTML of a website?

Press Ctrl+S and choose Webpage, HTML only, or press Ctrl+U to view the source and save it. For sites built by scripts, copy the rendered HTML from DevTools or use a Website to HTML tool.

### How do I download a website’s source code?

You can download its front end: the HTML, CSS, JavaScript and images your browser receives. The server code and database stay on the server and can’t be downloaded.

### Why is the downloaded HTML almost empty?

The site builds its page with JavaScript after it loads, so the saved file is just the shell. Copy the rendered HTML from the Elements panel, or use a tool that saves the page after it renders.

### Can I download HTML from a website online?

Yes. Paste the link into Sitepeel’s free Website to HTML tool. It opens the page, waits for it to render and gives you the HTML, one CSS file and the images in a ZIP.

### Is it legal to download a website’s HTML?

Saving a page to study it is usually fine. Its text, images and design still belong to the owner, so don’t republish them without permission.

## Further reading

- [Chrome DevTools: Sources panel](https://developer.chrome.com/docs/devtools/sources)
- [curl manual](https://curl.se/docs/manpage.html)
- [GNU Wget manual](https://www.gnu.org/software/wget/manual/wget.html)

## Related pages

- [Clone a website](https://sitepeel.dev/guides/how-to-clone-a-website/index.md): Clone a website page as HTML and CSS: load it fully, export it with the Clone page tool in Sitepeel, then check what you still need to rebuild.
- [Download CSS from a website](https://sitepeel.dev/guides/download-css-from-website/index.md): Download a website’s CSS: save its stylesheets from DevTools, make minified CSS readable, or get only the rules the page uses in one file with Website to HTML.
- [Download an entire website](https://sitepeel.dev/guides/download-entire-website/index.md): Download an entire website for offline viewing with HTTrack, SiteSucker or one wget command, see what copies badly and why, and save single pages instead.
- [Download a web page](https://sitepeel.dev/guides/download-web-page/index.md): Download a web page to read offline: Webpage, Complete, a single .mhtml file, a PDF or a phone’s offline copy, and why some saved pages look broken.
