October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk1 min

Angular NG05104: Root Element Was Not Found—How to Fix It

Angular NG05104 is a runtime bootstrap error: Angular cannot find the DOM node for the component it is starting. Match the loaded root tag to that component’s selector.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Angular’s NG05104 runtime error means it could not find the DOM element for the component it was asked to bootstrap. Check which component the application starts, then make sure the loaded page contains an element whose tag matches that component’s selector.

What NG05104 means

Angular raises NG05104, “Root element was not found”, when it tries to initialize a component but cannot find its corresponding node in the DOM. The component Angular initializes is identified either by an NgModule’s bootstrap property or, for a standalone application, by the component passed to bootstrapApplication. Angular lists NG05104 as a runtime error in its Error Encyclopedia.

As an Amazon Associate I earn from qualifying purchases.

How to find and fix the mismatch

  1. Identify the bootstrap component. Find the component named in the NgModule’s bootstrap property, or the first argument supplied to bootstrapApplication.

    What’s actually slowing this PC down?

    Pick the symptom - the matching free tool is one click away.

    Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  2. Check its selector. In that component’s definition, note the value of selector. Angular’s documented example uses my-app.

  3. Check the page’s root tag. Inspect the HTML loaded by the application and find the element intended to host the bootstrapped component. Its tag must match the selector. In Angular’s example, <app-root></app-root> does not match the selector my-app; changing the HTML to <my-app></my-app> resolves that mismatch.

  4. Verify the actual page Angular loads. Make the check against the HTML served to the application, not just a similarly named or unused template. The error concerns the DOM Angular is trying to bootstrap.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Why checking the bootstrap target matters

A selector mismatch is the cause illustrated on Angular’s official error page, not proof that every NG05104 incident has the same cause. Confirm the application’s actual bootstrap configuration and the DOM it loads; compare those two specific pieces rather than changing a tag based on an assumed root component.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.