---
schema_version: "1"
id: 3240c9545e47a28e3d4df839d8979bf484e04358c67ee62663d79b92ccd03ebf
title: getRoot()
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/aura-platform/guides/aura/ref-jsapi/ref-jsapi-dollara-getroot.md
canonical_url: https://developer.salesforce.com/docs/platform/aura-platform/guide/ref-jsapi-dollara-getroot.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 144a1e31c68e1f4144f5318396e917bbe060166471de6578ac007c22df717e53
products:
  - Lightning Aura Components Developer Guide
  - Platform Developer Content
---

# getRoot()

Gets the root component or application. For example, `$A.getRoot().get("v.attrName")` returns the value of the `attrName` attribute from the root component.

## Signature

`getRoot()`

