ObsidianAdvanced15 min
Dataview is the most powerful plugin in the Obsidian ecosystem. It turns your static notes into a queryable database — list notes by tag, sort by date, build tables of related content, and create dynamic dashboards that update automatically.
This guide covers DQL (Dataview Query Language) from basic LIST queries to inline JavaScript.
Install Dataview from Obsidian's community plugins:
DQL has four query types: LIST, TABLE, TASK, and CALENDAR. Start with the simplest:
```dataview
LIST
FROM #concept
SORT file.mtime DESC
LIMIT 10
```This lists the 10 most recently modified notes tagged #concept. Key syntax:
FROM — source: tags (#tag), folders ("folder/"), or links ([[note]])WHERE — filter conditionsSORT — order by any fieldLIMIT — restrict number of resultsBuild a dashboard note that summarizes your vault:
## Recently Created
```dataview
TABLE file.ctime as "Created", file.tags as "Tags"
FROM "10-notes"
SORT file.ctime DESC
LIMIT 5
```
## Tasks This Week
```dataview
TASK
FROM "10-notes"
WHERE !completed AND file.ctime >= date(today) - dur(7 days)
GROUP BY file.link
```
## Orphan Notes (no links)
```dataview
LIST
FROM "10-notes"
WHERE length(file.inlinks) = 0
```file.inlinks and file.outlinks to analyze your knowledge graphGROUP BY for organized outputFor complex logic, use the Dataview JS API:
```dataviewjs
const pages = dv.pages("#project")
.where(p => p.status == "active")
.sort(p => p.priority, "desc")
dv.table(
["Project", "Priority", "Status", "Due"],
pages.map(p => [p.file.link, p.priority, p.status, p.due])
)
```dv.pages()dv.el()Dataview troubleshooting:
Dataview opens up a world of possibilities: