Logs

Logs are important because it allows you to see what's happening inside the app, especially when a crisis happens. Now keeps logs of all of your deployments and allows you to search them.

Let's have a look at how you can access logs.

Accessing logs via the now CLI is simple as invoking this command:

now logs [deployment-url]

You can also use the domain name of your app to search logs:

now logs my-web-app.com

For more information on now logs, run the help command with:

now logs --help

The help command output of the 'now logs' command

Here's an advanced now logs command to let you inspect the last 10 HTTP GET requests.

now logs -a -q "GET" -n 10 my-web-app.com

Last 10 HTTP GET requests.

You can also access and search logs via your web dashboard at https://zeit.co/dashboard.
Click any of your deployment URLs inside the dashboard and start searching logs.

You may need to click the "Logs" link on the header (top right) to see logs.

Searching logs inside the web dashboard.