
You wire up a watch, mutate the data, and… nothing. No callback, no error, no red console line. Vue 3’s watcher API has a handful of rules that feel perfectly logical once you know them and are completely invisible until they bite you. Here are the four that account for most “my watcher never fires” bugs — each with a runnable snippet and the actual reason behind it.
Gotcha 1: watch(ref) is shallow, watch(reactive) is deep
Two sources that look interchangeable behave in opposite ways:
import { ref, reactive, watch } from 'vue'
const userRef = ref({ name: 'Ada', tags: ['math'] })
const userReactive = reactive({ name: 'Ada', tags: ['math'] })
watch(userRef, () => console.log('ref watcher fired'))
watch(userReactive, () => console.log('reactive watcher fired'))
userRef.value.name = 'Grace' // ❌ silence
userReactive.name = 'Grace' // ✅ "reactive watcher fired"
userRef.value = { name: 'Grace' } // ✅ fires — the .value reference changed
Why: when the source is a ref, Vue’s internal getter is essentially () => source.value, so the watcher only ever subscribes to the ref itself. Replacing .value triggers it; mutating what lives inside it does not. When the source is a reactive object, there is no .value to replace, so Vue deliberately traverses every property and the watcher becomes deep by default.
The fix is to opt in explicitly:
watch(userRef, cb, { deep: true })
Gotcha 2: Passing a property instead of a getter
const state = reactive({ count: 0 })
watch(state.count, cb) // ❌ passes the number 0 — never fires
watch(() => state.count, cb) // ✅ getter re-evaluates and tracks state.count
A watch source must be a ref, a reactive object, a getter function, or an array of those. state.count evaluates to a plain primitive at call time — the reactive link is already gone before watch ever sees the value. Dev builds log Invalid watch source, which is trivially easy to lose in a noisy console.
The getter form is also the fine-grained fix for Gotcha 1 — but it inherits the same shallow rule:
watch(() => state.user, cb) // only when state.user is reassigned
watch(() => state.user, cb, { deep: true }) // also on nested mutations
watch(() => state.user.name, cb) // primitive getter — no deep needed, cheapest option
Gotcha 3: With deep, oldValue is newValue
watch(userRef, (newVal, oldVal) => {
console.log(newVal === oldVal) // true 😱 on every deep mutation
}, { deep: true })
The mutation happened in place, so both arguments point at the same object. Any if (newVal.status !== oldVal.status) guard you write here is dead code. If you need the previous state, snapshot it yourself:
import { toRaw, watch } from 'vue'
let prev = structuredClone(toRaw(userRef.value))
watch(userRef, (val) => {
const snapshot = structuredClone(toRaw(val))
diff(prev, snapshot)
prev = snapshot
}, { deep: true })
Only the reference-replacement case hands you a genuinely distinct oldValue.
Gotcha 4: watchEffect stops tracking after await
watchEffect auto-tracks whatever you read — but only what you read synchronously, before the first await:
watchEffect(async () => {
const res = await fetch(`/api/user/${userId.value}`) // ✅ tracked (read before await)
data.value = await res.json()
console.log(locale.value) // ❌ NOT tracked — read after await
})
Once the effect yields to the microtask queue, Vue’s active-effect context is gone, so later reads register with nobody. Read every dependency up front, or switch to watch with an explicit source array.
The decision cheat sheet
watch(ref)→ fires on reassignment; nested mutations needdeep: truewatch(reactive)→ deep by default; nothing to opt intowatch(() => obj.prop)returning an object → fires on reassignment only; nested mutations needdeep: truewatch(() => obj.prop)returning a primitive → fires on every change;deepis meaningless herewatchEffect(...)→ tracks only synchronous reads
One performance caveat
deep: true walks the entire object graph on every trigger. On a 5,000-row cart that is real CPU burned on every keystroke. Prefer several narrow sources over one broad deep watcher:
// instead of a single deep watcher on the whole store
watch([() => cart.total, () => cart.items.length], onCartChange)
Vue 3.5+ also lets you cap traversal depth with a number: { deep: 2 }.
Debug checklist
- Watcher never fires → is the source a ref holding an object? Add
deep: true. - Watcher never fires → did you pass
obj.propinstead of() => obj.prop? oldValuelooks wrong → you are on a deep watcher; snapshot manually.- Watcher feels slow or fires constantly → split one deep watcher into primitive getters.