Back to Nuxt

NUXT_E6001

docs/errors/e6001.md

4.5.2547 B
Original Source

E6001

A head composable such as useHead() was called without an active Unhead instance. This happens when it runs outside a valid Nuxt context, for example in a detached async callback after the Nuxt instance is no longer available.

Resolution

Call head composables synchronously inside a component setup(), a Nuxt plugin, or route middleware. If you need them after an await, capture the Nuxt context first:

ts
const nuxtApp = useNuxtApp()
await someAsyncWork()
nuxtApp.runWithContext(() => useHead({ title: 'Late title' }))