> ## Documentation Index
> Fetch the complete documentation index at: https://docs.oculusproxies.com/llms.txt
> Use this file to discover all available pages before exploring further.

# How to Set Up Oculus Proxies With Playwright

> Streamline your web automation and scraping workflows! Integrating Oculus Proxies with Playwright allows you to securely and anonymously manage your automation tasks while reducing the risk of detection and IP bans. This guide will help you configure Oculus Proxies in Playwright step by step.

<img src="https://mintcdn.com/oculus/4CVh05wC6-hsrqWV/integration-guides/img/oculus_integrations/Playwright.png?fit=max&auto=format&n=4CVh05wC6-hsrqWV&q=85&s=52072711dd3758adffa7d0cef980b5ea" alt="title" width="720" height="200" data-path="integration-guides/img/oculus_integrations/Playwright.png" />

## What is Playwright?

Playwright is a modern, open-source Node.js library for automating browsers. It supports multiple browser engines, including Chromium, Firefox, and WebKit, and provides powerful tools for web scraping, testing, and automation. Its cross-browser capabilities and robust API make it a favorite choice for developers and data enthusiasts.&#x20;

<Tip>
  If you're using **Oculus** to access search engines like **Google, Bing, or Yandex** and facing connection issues, the proxy type could be the reason. **ISP Premium Proxies** ensure stable and unrestricted access, preventing blocks that standard proxies might encounter. Switching to **ISP Premium Proxies** can help maintain smooth and reliable performance.
</Tip>

## How to Integrate Oculus Proxies With Playwright

<Steps>
  <Step title="Install Required Tools">
    1\. **Node.js**: Download and install it from [nodejs.org](https://nodejs.org/).

    2\. **Playwright Package**: Install Playwright in your Node.js project by running:

    ```bash theme={null}
    npm install playwright
    ```
  </Step>

  <Step title="Grab Your Oculus Proxy Credentials">
    1\. Log in to your [Oculus Dashboard](https://oculusproxies.com/dashboard/page/plans).

    2\. Copy your **Host**, **Port**, **Username**, and **Password** for later use.
  </Step>

  <Step title="Configure Playwright to Use Oculus Proxies">
    1\. Add the proxy details in Playwright’s browser launch options using the format `host:port`.

    2\. Pass your **username** and **password** for proxy authentication.
  </Step>

  <Step title="Example Code">
    Here’s an example to help you get started:

    ```javascript theme={null}
    const { chromium } = require('playwright');

    (async () => {
      // Launch browser with proxy settings
      const browser = await chromium.launch({
        headless: false,  // Set to true for headless mode
        proxy: {
          server: 'http://[HOST]:[PORT]',  // Replace with your proxy host and port
          username: '[USERNAME]',        // Replace with your proxy username
          password: '[PASSWORD]'         // Replace with your proxy password
        }
      });

      const context = await browser.newContext();
      const page = await context.newPage();

      // Test the proxy by visiting an IP verification website
      await page.goto('http://httpbin.org/ip');
      // Capture a screenshot to verify the setup
      await page.screenshot({ path: 'example.png' });

      await browser.close();
    })();
    ```
  </Step>
</Steps>

**You're Ready to Automate!** By integrating **Oculus Proxies** with **Playwright**, you gain the ability to handle web scraping and automation tasks with enhanced privacy and reliability. Enjoy seamless, secure, and efficient workflows while minimizing the risk of detection and bans.
