# Pagination

All results returned are paginated by default.&#x20;

```javascript
{
    "meta": {
        "next": "xqErdcgltHGs",
        "previous": null,
        "total_count": 39
    },
    "results": [
        {
            "created_at": "2021-05-06T07:00:21Z",
            "description": "Test",
            "favorite": false,
            "id": "f2eb2dab-a861-4960-b5f4-d54c61552f7d",
            "name": "Test project",
            "self": "http://localhost:4000/api/v1/projects/f2eb2dab-a861-4960-b5f4-d54c61552f7d",
            "templates": "http://localhost:4000/api/v1/projects/f2eb2dab-a861-4960-b5f4-d54c61552f7d/templates",
            "updated_at": "2021-05-06T07:00:21Z"
        },
        ...
    ]
}
```

`meta` field contains the pagination metadata and `result` field contains the limited result set.

### Querying for next set of result

Append `after` query string with the value from `next` metadata field.

```javascript
https://api.usestencil.com/v1/projects?after=xqErdcgltHGs
```

### Querying for previous set of result

Append `before` query string with the value from `previous` metadata field.

```javascript
https://api.usestencil.com/v1/projects?before=xqErdcgltHGs
```

### Limiting result

Append `limit=<integer>` to limit the results set

```javascript
https://api.usestencil.com/v1/projects?limit=10
```

{% hint style="info" %}
You can combine `limit` with either `after` and `before`
{% endhint %}
