1 ---
2 title: npm-explore
3 section: 1
4 description: Browse an installed package
5 github_repo: npm/cli
6 github_branch: release/v8
7 github_path: docs/lib/content/commands/npm-explore.md
8 redirect_from:
9 - /cli-documentation/v8/cli-commands/explore
10 - /cli-documentation/v8/cli-commands/npm-explore
11 - /cli-documentation/v8/commands/explore
12 - /cli-documentation/v8/commands/npm-explore
13 - /cli-documentation/v8/explore
14 - /cli-documentation/v8/npm-explore
15 - /cli/v8/cli-commands/explore
16 - /cli/v8/cli-commands/npm-explore
17 - /cli/v8/commands/explore
18 - /cli/v8/explore
19 - /cli/v8/npm-explore
20 ---
21
22 ### Synopsis
23
24 ```bash
25 npm explore <pkg> [ -- <command>]
26 ```
27
28 Note: This command is unaware of workspaces.
29
30 ### Description
31
32 Spawn a subshell in the directory of the installed package specified.
33
34 If a command is specified, then it is run in the subshell, which then immediately terminates.
35
36 This is particularly handy in the case of git submodules in the `node_modules` folder:
37
38 ```bash
39 npm explore some-dependency -- git pull origin master
40 ```
41
42 Note that the package is _not_ automatically rebuilt afterwards, so be sure to use `npm rebuild <pkg>` if you make any changes.
43
44 ### Configuration
45
46 #### `shell`
47
48 - Default: SHELL environment variable, or "bash" on Posix, or "cmd.exe" on Windows
49 - Type: String
50
51 The shell to run for the `npm explore` command.
52
53 ### See Also
54
55 - [npm folders](/cli/v8/configuring-npm/folders)
56 - [npm edit](/cli/v8/commands/npm-edit)
57 - [npm rebuild](/cli/v8/commands/npm-rebuild)
58 - [npm install](/cli/v8/commands/npm-install)