@@ -14,36 +14,36 @@ The Model Context Protocol (MCP) is an open protocol that enables seamless integ
14
14
15
15
You can either use our Server hosted on NPM or run it completely locally by cloning this repo.
16
16
17
- #### To run on NPM (Recommended)
17
+ ### To run on NPM (Recommended)
18
18
19
19
Go into your MCP Config JSON and add the Browserbase Server:
20
20
21
21
``` json
22
- {
23
- "mcpServers" : {
24
- "browserbase" : {
25
- "command" : " npx" ,
26
- "args" : [" @browserbasehq/mcp-server-browserbase" ],
27
- "env" : {
28
- "BROWSERBASE_API_KEY" : " " ,
29
- "BROWSERBASE_PROJECT_ID" : " "
30
- }
22
+ {
23
+ "mcpServers" : {
24
+ "browserbase" : {
25
+ "command" : " npx" ,
26
+ "args" : [" @browserbasehq/mcp-server-browserbase" ],
27
+ "env" : {
28
+ "BROWSERBASE_API_KEY" : " " ,
29
+ "BROWSERBASE_PROJECT_ID" : " "
31
30
}
32
31
}
33
32
}
33
+ }
34
34
```
35
35
36
36
Thats it! Reload your MCP client and Claude will be able to use Browserbase.
37
37
38
- #### To run 100% local:
38
+ ### To run 100% local:
39
39
40
40
``` bash
41
- # Clone the Repo
42
- git clone https://github.com/browserbase/mcp-server-browserbase.git
41
+ # Clone the Repo
42
+ git clone https://github.com/browserbase/mcp-server-browserbase.git
43
43
44
- # Install the dependencies in the proper directory and build the project
45
- cd browserbase
46
- npm install && npm run build
44
+ # Install the dependencies in the proper directory and build the project
45
+ cd browserbase
46
+ npm install && npm run build
47
47
48
48
```
49
49
@@ -54,18 +54,18 @@ Then in your MCP Config JSON run the server. To run locally we can use STDIO or
54
54
To your MCP Config JSON file add the following:
55
55
56
56
``` json
57
- {
58
- "mcpServers" : {
59
- "browserbase" : {
60
- "command" : " node" ,
61
- "args" : [" /path/to/mcp-server-browserbase/browserbase/cli.js" ],
62
- "env" : {
63
- "BROWSERBASE_API_KEY" : " " ,
64
- "BROWSERBASE_PROJECT_ID" : " "
65
- }
57
+ {
58
+ "mcpServers" : {
59
+ "browserbase" : {
60
+ "command" : " node" ,
61
+ "args" : [" /path/to/mcp-server-browserbase/browserbase/cli.js" ],
62
+ "env" : {
63
+ "BROWSERBASE_API_KEY" : " " ,
64
+ "BROWSERBASE_PROJECT_ID" : " "
66
65
}
67
66
}
68
67
}
68
+ }
69
69
```
70
70
71
71
### SSE:
@@ -128,19 +128,18 @@ Here are our docs on [Proxies](https://docs.browserbase.com/features/proxies).
128
128
To use proxies in STDIO, set the --proxies flag in your MCP Config:
129
129
130
130
``` json
131
- {
132
- "mcpServers" : {
133
- "browserbase" : {
134
- "command" : " npx" ,
135
- "args" : [" @browserbasehq/mcp-server-browserbase" , " --proxies" ],
136
- "env" : {
137
- "BROWSERBASE_API_KEY" : " " ,
138
- "BROWSERBASE_PROJECT_ID" : " "
139
- }
131
+ {
132
+ "mcpServers" : {
133
+ "browserbase" : {
134
+ "command" : " npx" ,
135
+ "args" : [" @browserbasehq/mcp-server-browserbase" , " --proxies" ],
136
+ "env" : {
137
+ "BROWSERBASE_API_KEY" : " " ,
138
+ "BROWSERBASE_PROJECT_ID" : " "
140
139
}
141
140
}
142
141
}
143
-
142
+ }
144
143
```
145
144
146
145
### Contexts
@@ -150,19 +149,18 @@ Here are our docs on [Contexts](https://docs.browserbase.com/features/contexts)
150
149
To use contexts in STDIO, set the --contextId flag in your MCP Config:
151
150
152
151
``` json
153
- {
154
- "mcpServers" : {
155
- "browserbase" : {
156
- "command" : " npx" ,
157
- "args" : [" @browserbasehq/mcp-server-browserbase" , " --contextId" , " " ],
158
- "env" : {
159
- "BROWSERBASE_API_KEY" : " " ,
160
- "BROWSERBASE_PROJECT_ID" : " "
161
- }
152
+ {
153
+ "mcpServers" : {
154
+ "browserbase" : {
155
+ "command" : " npx" ,
156
+ "args" : [" @browserbasehq/mcp-server-browserbase" , " --contextId" , " " ],
157
+ "env" : {
158
+ "BROWSERBASE_API_KEY" : " " ,
159
+ "BROWSERBASE_PROJECT_ID" : " "
162
160
}
163
161
}
164
162
}
165
-
163
+ }
166
164
```
167
165
168
166
### Cookie Injection
@@ -174,23 +172,23 @@ You can flag cookies into the MCP by adding the cookies.json to your MCP Config.
174
172
To use proxies in STDIO, set the --proxies flag in your MCP Config. Your cookies JSON must be in the type of [ Playwright Cookies] ( https://playwright.dev/docs/api/class-browsercontext#browser-context-cookies )
175
173
176
174
``` json
177
- {
178
- "mcpServers" : {
179
- " browserbase" {
180
- "command" : " npx" ,
181
- "args" : [
182
- " @browserbasehq/mcp-server-browserbase" , " --cookies" ,
183
- '{
184
- "cookies" : json,
185
- }'
186
- ],
187
- "env" : {
188
- "BROWSERBASE_API_KEY" : " " ,
189
- "BROWSERBASE_PROJECT_ID" : " "
190
- }
175
+ {
176
+ "mcpServers" : {
177
+ " browserbase" {
178
+ "command" : " npx" ,
179
+ "args" : [
180
+ " @browserbasehq/mcp-server-browserbase" , " --cookies" ,
181
+ '{
182
+ "cookies" : json,
183
+ }'
184
+ ],
185
+ "env" : {
186
+ "BROWSERBASE_API_KEY" : " " ,
187
+ "BROWSERBASE_PROJECT_ID" : " "
191
188
}
192
189
}
193
190
}
191
+ }
194
192
```
195
193
196
194
### Browser Viewport Sizing
@@ -200,22 +198,22 @@ The default viewport sizing for a browser session is 1024 x 768. You can adjust
200
198
Here's how to use it for custom browser sizing. We recommend to stick with 16:9 aspect ratios (ie: 1920 x 1080, 1280, 720, 1024 x 768)
201
199
202
200
``` json
203
- {
204
- "mcpServers" : {
205
- "browserbase" : {
206
- "command" : " npx" ,
207
- "args" : [
208
- " @browserbasehq/mcp-server-browserbase" ,
209
- " --browserHeight 1080" ,
210
- " --browserWidth 1920" ,
211
- ],
212
- "env" : {
213
- "BROWSERBASE_API_KEY" : " " ,
214
- "BROWSERBASE_PROJECT_ID" : " "
215
- }
201
+ {
202
+ "mcpServers" : {
203
+ "browserbase" : {
204
+ "command" : " npx" ,
205
+ "args" : [
206
+ " @browserbasehq/mcp-server-browserbase" ,
207
+ " --browserHeight 1080" ,
208
+ " --browserWidth 1920" ,
209
+ ],
210
+ "env" : {
211
+ "BROWSERBASE_API_KEY" : " " ,
212
+ "BROWSERBASE_PROJECT_ID" : " "
216
213
}
217
214
}
218
215
}
216
+ }
219
217
```
220
218
221
219
## Structure
0 commit comments