---
title: "Astro 7.2"
url: https://daily.dev/posts/astro-7-2-rylsv9nok
source_url: https://astro.build/blog/astro-720
type: article
source: "Astro"
published: 2026-08-06T16:22:40.608Z
updated: 2026-08-20T04:28:10.476Z
tags: ["webdev", "astro"]
reading_time: 5
upvotes: 46
comments: 1
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Astro 7.2

**[Astro](https://daily.dev/sources/astro_source)** · 5 min read · 46 upvotes · 1 comments

## Summary

Astro 7.2 ships four notable changes. The headline feature is experimental incremental static builds: routes can now return a `cacheKey` from `getStaticPaths()`, and Astro skips re-rendering pages whose module graph hash and cache key both match the previous build, storing the cache in `node_modules/.astro/`. A new `session: false` option lets SSR projects opt out of session support entirely, removing the session runtime from the bundle; projects without a configured driver also benefit automatically via tree-shaking. The `astro preview` command gains the same background mode introduced for `astro dev` in Astro 7, allowing the preview server to run detached with log file output and follow-up management commands. Finally, `logger.entrypoint` now accepts a plain relative string in addition to the previously required URL object.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://astro.build/blog/astro-720>

## Questions this post answers

### How does incremental static builds work in Astro 7.2 and how do I enable it?

Incremental static builds in Astro 7.2 are enabled with the `experimental.incrementalBuild` flag. Each route opts in by returning a `cacheKey` per path from `getStaticPaths()` — for content collections, `entry.digest` is recommended. Astro also hashes the full module graph (template, layouts, components, assets, packages); a page is only reused when both the module hash and `cacheKey` match the previous build. The cache lives in `node_modules/.astro/` by default.

_Teams running large Astro docs or marketing sites track build performance changes like this on daily.dev._

### How do I disable session support in Astro to reduce bundle size?

Set `session: false` in your Astro config. This prevents Cloudflare, Netlify, and Node adapters from wiring up their default session driver and removes the session runtime from the SSR bundle. `Astro.session` becomes `undefined`, a state its type already allowed, so existing `if (Astro.session)` guards continue to work. Projects with no driver configured also benefit automatically through tree-shaking without setting the flag.

_Developers optimizing Astro SSR cold-start times find relevant bundle-size discussions on daily.dev._

## Community discussion

Top comments from developers on daily.dev.

**@seyoungcho** · 5 upvotes

> Incremental static builds + auto tree-shaken sessions — Astro 7.2 is quietly shipping some really smart defaults.

## Similar posts on daily.dev

- [Astro 7.0](https://daily.dev/posts/astro-7-0-2arekjquc) · Astro · 202 upvotes · 13 comments

---

Tags: [#webdev](https://daily.dev/tags/webdev), [#astro](https://daily.dev/tags/astro)

[View this post on daily.dev](https://daily.dev/posts/astro-7-2-rylsv9nok)
