Contents

    Guides

    Extending Browser Testing with Cypress and Cloud

    Published on

    February 25, 2026
    Extending Browser Testing with Cypress and Cloud

    As web applications become increasingly complex, ensuring compatibility across multiple browsers has never been more important.

    While testing your application, it's essential to verify how it behaves on different browsers, especially with modern frameworks like Cypress.

    Cypress, a popular end-to-end testing framework, offers native support for testing in several major browsers like Chrome, Firefox, and Electron, and even introduces experimental support for WebKit (the engine behind Safari).

    However, understanding the limits of Cypress’s browser support and knowing how to configure and run tests across various browsers is key to achieving thorough test coverage.

    This article explores the browsers that Cypress supports, how to configure them, and the best practices for running tests across different browsers for reliable, cross-platform web applications.

    Understanding Cypress Browsers

    Cypress is an end-to-end testing framework that interacts directly with the browser, providing faster and more reliable test execution compared to traditional WebDriver-based tools. Cypress’s architecture runs tests inside the browser, unlike WebDriver, which relies on a separate server to communicate with the browser.

    How Cypress Executes Tests Inside Browsers

    • Direct Execution: Cypress runs within the browser’s execution loop, eliminating the need for an intermediary server like WebDriver. This direct interaction ensures faster execution and better synchronization.
    • Real-Time Feedback: As tests run, Cypress provides real-time feedback, allowing you to interact with the application, inspect elements, and debug instantly.
    • Automatic Waiting: Cypress automatically waits for elements to load and actions to complete, reducing the need for manual waits and improving test reliability.

    Difference Between Cypress and WebDriver Approaches

    1. Architecture: Cypress runs inside the browser, executing commands in real-time, while WebDriver uses an external server to communicate with the browser, causing delays.

    2. Speed & Reliability: Cypress provides faster and more reliable tests due to its direct control over the browser, whereas WebDriver can be slower and more prone to timing issues.

    3. Debugging: Cypress offers real-time, interactive debugging within the browser, while WebDriver typically requires external tools for debugging.

    4. Browser Support: Cypress supports modern browsers like Chrome, Firefox, and Electron, with experimental WebKit support. For broader browser support, WebDriver is more versatile, supporting a wider range of browsers, including older versions and Internet Explorer.

    5. Mobile Testing: Cypress doesn’t natively support mobile testing but can simulate mobile environments via viewport adjustments. WebDriver (with Appium) is better suited for mobile testing across a wide range of devices.

    Supported Browsers in Cypress

    Cypress supports several modern browsers, allowing you to test your web application across different environments.

    While Cypress doesn’t support every browser on the market, it provides robust support for the most commonly used browsers, ensuring broad compatibility and real-world test coverage.

    1. Chrome-family Browsers

    • Chrome: Cypress fully supports Google Chrome, which is the most widely used browser for web applications. It's the default browser for running tests in Cypress due to its performance and stability.
    • Chromium: The open-source version of Chrome, Chromium, is also supported in Cypress and can be used for testing.
    • Microsoft Edge: Cypress supports Microsoft Edge (Chromium-based), ensuring that tests run properly on the latest version of this browser.

    All of these Chrome-family browsers offer full support for modern web standards and Cypress commands, ensuring stable test execution.

    2. Firefox

    • Firefox is supported by Cypress in both stable and developer editions. This allows you to test how your application behaves in Firefox, which has a different rendering engine (Gecko) compared to Chrome.
    • Firefox support is particularly important for testing performance, JavaScript compatibility, and CSS rendering in an open-source browser that emphasizes user privacy and security.

    3. Electron

    • Electron is a browser bundled with Cypress and is designed for headless testing in Cypress. It is a minimal, Chromium-based browser that allows you to run tests in an isolated environment, which is useful for testing basic functionality without the need for a full browser window.
    • Electron is lightweight and ideal for continuous integration (CI) environments, where speed and efficiency are key. However, it is not meant for simulating actual user behavior and does not provide the full functionality of browsers like Chrome or Firefox.

    4. WebKit (Experimental)

    • WebKit is the engine behind Safari and is supported in Cypress through experimental features. This enables you to test your web applications in environments similar to Safari on macOS and iOS.
    • While WebKit support is still experimental, it is essential for testing web apps targeting Apple devices. However, because it's still in the experimental phase, it might not yet provide the full stability and compatibility seen in the more widely supported browsers like Chrome and Firefox.

    5. Browsers Not Natively Supported

    • Internet Explorer (IE) and other legacy browsers are not natively supported by Cypress. For testing in these browsers, you would need to integrate Cypress with platforms like BrowserStack, which offer cloud-based cross-browser testing, including support for older browsers.

    How Cypress Detects and Launches Browsers

    One of the key features of Cypress is its ability to run tests directly inside modern browsers, ensuring real-time interaction with your application. Here's how Cypress handles browser detection and launching for your tests:

    1. Automatic Browser Detection

    When you install Cypress, it automatically detects all the browsers available on your system. This includes popular browsers like Chrome, Chromium, Firefox, and Electron.

    On macOS, if you have Safari installed, Cypress can also detect WebKit (Safari's engine) as an available option for testing.

    Once Cypress is installed, it doesn't require any complex setup or configuration to detect browsers; it will automatically list the supported browsers that are installed on your system.

    When running tests, Cypress queries your local machine’s browser installations and dynamically populates the available options, ensuring that you can run tests in any of the supported browsers.

    For instance:

    • On Windows: Chrome, Chromium, and Edge will be detected if installed.
    • On macOS: In addition to Chrome, Chromium, and Edge, Safari (via WebKit) can also be detected.
    • On Linux: Chrome and Chromium are typically the default browsers detected by Cypress.

    2. Specifying the Browser in Cypress

    Once Cypress detects the installed browsers, you can specify which browser you want to run your tests in. You can do this either interactively through the Cypress Test Runner (UI mode) or via the command line interface (CLI).

    Interactive Mode

    If you’re running tests in Cypress Open mode, the available browsers will be listed in the UI. You can simply click on the desired browser, and Cypress will launch it to execute your tests.

    npx cypress open

    Command Line Interface

    For headless testing or running tests from a script (e.g., in a CI pipeline), you can specify the browser directly using the --browser flag.

    The following command runs tests in Chrome:

    npx cypress run --browser chrome

    Similarly, for Firefox, you can specify:

    npx cypress run --browser firefox

    You can also run tests on specific browsers programmatically, like so:

    npx cypress run --browser electron

    By using the --browser flag, Cypress runs the tests in the chosen browser, regardless of the default browser configuration.

    3. Handling Browser Versions and Updates

    Cypress ensures that it runs tests in the latest stable versions of the supported browsers (Chrome, Firefox, Electron). When Cypress detects a browser, it doesn’t simply check if the browser is installed—it also verifies the version to ensure compatibility. For example:

    • When running tests on Chrome, Cypress will check that the version is recent enough to support the necessary Web APIs and standards for testing.
    • If you're using Electron (which is bundled with Cypress), Cypress automatically keeps it updated to the latest version available in the installed Cypress package, so no separate updates are necessary for Electron.

    If you need to test with a specific version of a browser that isn't automatically detected or supported, you can install the required version manually and ensure it's available in your system’s environment variables.

    4. Fallback to Default Browser

    If you don’t specify a browser when running Cypress, it will default to the first browser listed in the available browsers list. Typically, this is Electron, but it can vary depending on your configuration or operating system.

    For example:

    npx cypress run

    This command will run the tests using the default browser (Electron) unless another browser is specified.

    5. Integrating Cypress with Browser Profiles

    For more advanced setups, Cypress allows you to pass custom browser profiles when running tests, particularly for Chrome. This can be useful if you need to run tests with custom browser settings, like a specific extension or different user data.

    To use a custom Chrome profile, you can specify additional arguments using the --config option:

    npx cypress run --browser chrome --config chromeWebSecurity=false

    This allows you to modify specific behaviors of the browser during test execution, like disabling web security for certain tests or changing viewport sizes dynamically.

    6. Running Tests Across Multiple Browsers

    Cypress allows you to run your test suite on multiple browsers in parallel, providing coverage for different environments without needing to write separate test scripts.

    For example, you can execute tests on Chrome and Firefox by running separate commands:

    npx cypress run --browser chrome npx cypress run --browser firefox

    For CI/CD pipelines, you can integrate these commands to run the same tests across multiple browsers automatically, ensuring cross-browser compatibility for your web application.

    7. Browser-Specific Configuration

    While Cypress automatically detects and launches browsers, you may need to customize settings depending on the browser you're testing with.

    For instance, Cypress provides options for configuring viewport sizes, time zones, and user agents.

    These configurations can be set in the cypress.json configuration file, or they can be passed as command line arguments.

    Example configurations:

    { "viewportWidth": 1280, "viewportHeight": 800 }

    This config ensures that Cypress uses a consistent viewport size across different browsers and tests.

    Running Tests in Different Browsers

    One of the key features of Cypress is its ability to run tests in various modern browsers, ensuring that your web application behaves as expected across different environments.

    While Cypress doesn’t support all browsers natively, it does allow you to run your tests on the most widely used browsers, including Chrome, Firefox, Electron, and WebKit (experimental support for Safari). Here’s how you can run Cypress tests in different browsers.

    1. Running Tests in Cypress Open Mode

    Cypress Open provides an interactive test running environment, where you can choose which browser to run your tests in. This is the most straightforward way to execute tests in multiple browsers during development. The steps include:

    1. Launch Cypress Open

    npx cypress open

    2. Select Your Browser

    Once Cypress Open is launched, you'll see a list of supported browsers installed on your machine. Simply click on the browser you wish to use (e.g., Chrome, Firefox, Edge, Electron) to start running your tests interactively in that browser.

    3. Run the Tests

    After selecting a browser, Cypress will run the tests in that browser. You’ll be able to see real-time logs, snapshots, and interact with the application directly as the tests execute.

    2. Running Tests in Headless Mode

    For automated testing, especially in CI/CD pipelines, headless mode is typically preferred. In this mode, Cypress runs tests without launching a visible browser window. This improves execution speed and is ideal for continuous integration environments.

    To run tests in headless mode, use the --browser flag followed by the browser you want to use. Here’s how you can run tests in different browsers using headless mode:

    1. Run Tests in Chrome (Headless)

    npx cypress run --browser chrome

    This will run your tests in Chrome without opening the browser window.

    2. Run Tests in Firefox (Headless)

    npx cypress run --browser firefox

    This command runs your tests in Firefox in headless mode.

    3. Run Tests in Electron (Headless)

    npx cypress run --browser electron

    Electron is the default headless browser used by Cypress, and it runs tests faster, making it ideal for CI workflows.

    4. Run Tests in WebKit (Experimental)

    npx cypress run --browser webkit

    WebKit, which powers Safari, is available as an experimental feature in Cypress. This allows you to run tests similar to Safari without having to use the full browser.

    3. Running Tests in Multiple Browsers

    In Cypress, you can run the same test suite in multiple browsers to ensure that your web application performs consistently across different environments. To do this, you can execute the tests in multiple browsers in succession or in parallel, depending on your workflow.

    Example: You can run the same tests on Chrome, Firefox, and Electron by running the following commands separately.

    1. Run Tests in Chrome

    npx cypress run --browser chrome

    2. Run Tests in Firefox

    npx cypress run --browser firefox

    3. Run Tests in Electron

    npx cypress run --browser electron

    If you want to speed up execution, consider running tests in multiple browsers in parallel by using CI/CD tools, such as GitHub Actions, CircleCI, or Jenkins, that allow running multiple jobs at once.

    4. Running Tests in Different Browsers in CI/CD Pipelines

    In a CI/CD pipeline, you may want to run tests on different browsers automatically to ensure cross-browser compatibility. This is typically done by specifying the browser in the pipeline configuration file.

    Example with GitHub Actions: Here’s how you can set up your GitHub Actions workflow to run tests on Chrome and Firefox.

    name: Cypress Tests on: push: branches: - main jobs: test: runs-on: ubuntu-latest steps: - name: Checkout code uses: actions/checkout@v2 - name: Set up Node.js uses: actions/setup-node@v2 with: node-version: '14' - name: Install dependencies run: npm install - name: Run Cypress tests on Chrome run: npx cypress run --browser chrome - name: Run Cypress tests on Firefox run: npx cypress run --browser firefox

    This configuration ensures that Cypress tests are run in Chrome and Firefox every time you push changes to the main branch.

    Browser Limitations in Cypress

    While Cypress supports popular modern browsers like Chrome, Firefox, and Electron, there are some notable limitations:

    1. Limited Browser Support: Cypress does not support older browsers like Internet Explorer or certain versions of Safari. For testing these browsers, external services like BrowserStack are required.
    2. WebKit (Safari) Support is Experimental: WebKit, the engine behind Safari, is supported in an experimental capacity. This means it may not provide full compatibility and stability like Chrome or Firefox.
    3. Mobile Browser Testing Limitations: Cypress doesn't natively support testing on mobile browsers. While you can simulate mobile views by adjusting viewport sizes, testing on real mobile devices requires platforms like BrowserStack.
    4. Cross-Browser Testing Challenges: Cypress primarily supports Chrome, Firefox, Electron, and WebKit. For comprehensive cross-browser testing across all platforms, especially older browsers, services like BrowserStack are needed.
    5. Feature Parity Between Mobile and Desktop Browsers: Cypress is optimized for desktop browsers and doesn't offer full mobile emulation. For mobile-specific testing, tools like Appium or cloud-based platforms are more suitable.

    Best Practices for Cross‑Browser Testing

    To ensure your web application performs consistently across different browsers, it’s essential to follow best practices that address common challenges in cross-browser testing:

    • Test on Real Browsers: Always run tests on real browsers rather than relying solely on emulators or simulators to ensure accuracy.
    • Use Cypress with Multiple Browsers: Run tests in supported browsers like Chrome, Firefox, Electron, and WebKit to ensure compatibility across major platforms.
    • Leverage Cloud Testing Services: For browsers not natively supported by Cypress (e.g., Internet Explorer), use cloud services like BrowserStack to extend your coverage.
    • Automate Browser Selection: Use CI/CD pipelines to automate browser testing, running the same tests on multiple browsers in parallel to save time.
    • Ensure Consistent Viewports: Configure consistent viewport sizes for cross-browser tests to avoid layout issues caused by differing screen resolutions.
    • Account for Browser-Specific Behavior: Be aware of browser-specific quirks (e.g., JavaScript execution, CSS rendering) and write custom tests or assertions when needed.
    • Regularly Update Browsers: Keep browsers up to date to avoid compatibility issues due to older versions of browsers that may behave differently.

    Extending Browser Coverage with Cloud Platforms

    To expand Cypress's native browser support and test on a broader range of environments, integrating with cloud-based platforms is highly effective. Here’s how cloud platforms help extend your browser coverage:

    • Test on Legacy Browsers: Cypress doesn’t support older browsers like Internet Explorer. Using cloud services like BrowserStack, you can run tests on legacy browsers and older versions not supported natively.
    • Cross-Device Testing: Cloud platforms provide access to real devices, allowing you to test mobile browsers and real-world conditions, including responsive design and touch interactions.
    • Multiple Browser Versions: Cloud services offer access to multiple versions of browsers (e.g., older versions of Safari, Chrome, Firefox), ensuring that your web app works across a wide range of environments.
    • Parallel Testing: Running tests in parallel on cloud platforms speeds up test execution by distributing your tests across multiple devices and browsers, improving efficiency in CI/CD pipelines.
    • Scalability: Cloud platforms allow you to scale up testing, running multiple browser combinations and configurations without the need for complex local setup or maintenance.

    Conclusion

    Cypress provides powerful and efficient cross-browser testing capabilities, ensuring that your web applications are thoroughly tested across modern browsers like Chrome, Firefox, Electron, and WebKit. However, for comprehensive coverage, legacy browsers or real mobile devices, integrating Cypress with cloud platforms like BrowserStack Automate can extend your testing capabilities even further.

    BrowserStack Automate allows you to run Cypress tests across a wide range of browsers, versions, and devices in the cloud, without the need for local infrastructure. This ensures that your application works flawlessly across all platforms, helping you deliver a seamless user experience no matter the browser or device your users prefer.

    Try BrowserStack Now

    Data-rich bug reports loved by everyone

    Get visual proof, steps to reproduce and technical logs with one click

    Make bug reporting 50% faster and 100% less painful

    Rating LogosStars
    4.6
    |
    Category leader

    Liked the article? Spread the word

    Continue reading

    No items found.

    Put your knowledge to practice

    Try Bird on your next bug - you’ll love it

    “Game changer”

    Julie, Head of QA

    star-ratingstar-ratingstar-ratingstar-ratingstar-rating

    Overall rating: 4.7/5

    Try Bird later, from your desktop