Angular: NG0300: Multiple components match node with tagname app-x: A and B
Two components in scope share the same selector, so Angular cannot decide which one renders for that tag.
NG0300: Multiple components match node with tagnameMultiple components match node with tagnametwo components match the same selector Meaning
A given element can be matched by only one component. It happens when two components (or modules) declare the same selector, when a duplicate component is imported twice through different NgModules, or when a library component clashes with yours.
Common causes
- Two components with identical
selectorvalues in scope - The same component declared in two NgModules
- Own component selector clashes with a library one (
app-buttonvs a UI kit) - Copy-pasted component not renamed
- Standalone import list containing two components with one selector
⚡ Quick fix
- Give each component a unique selector prefix
- Remove one of the duplicate imports/declarations
- Search the project for the selector named in the message
Detailed fix by platform
Angular CLI
- Search quickly:
grep -rn "selector: 'app-x'" src/ - Set a project prefix in angular.json (
"prefix": "acme") and regenerate
How to diagnose
- Selector — Which two components are named?
- Scope — Where are both imported or declared?
- Origin — Library or own code?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- Cannot find control with name Angular: Error: Cannot find control with name: 'email' (reactive forms)
- Could not find the builder's node package Angular CLI: Could not find the '@angular-devkit/build-angular:browser' builder's node package / Cannot find module '@angular-devkit/build-angular/package.json'
- exceeded maximum budget Angular build: Error: bundle initial exceeded maximum budget. Budget 1.00 MB was not met by 120.00 kB with a total of 1.12 MB
Most viewed in Angular
Other ways to find it
Where this error sits
Origin: On your device. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 15 Oct 2026