Python vs Selenium

Get Advice Icon

Need advice about which tool to choose?Ask the StackShare community!

Python
Python

29.1K
22.3K
+ 1
5.9K
Selenium
Selenium

4K
2.6K
+ 1
444
Add tool

Python vs Selenium: What are the differences?

What is Python? A clear and powerful object-oriented programming language, comparable to Perl, Ruby, Scheme, or Java. Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.

What is Selenium? Web Browser Automation. Selenium automates browsers. That's it! What you do with that power is entirely up to you. Primarily, it is for automating web applications for testing purposes, but is certainly not limited to just that. Boring web-based administration tasks can (and should!) also be automated as well.

Python can be classified as a tool in the "Languages" category, while Selenium is grouped under "Browser Testing".

"Great libraries", "Readable code" and "Beautiful code" are the key factors why developers consider Python; whereas "Automates browsers", "Testing" and "Essential tool for running test automation" are the primary reasons why Selenium is favored.

Python and Selenium are both open source tools. It seems that Python with 25.3K GitHub stars and 10.5K forks on GitHub has more adoption than Selenium with 14.9K GitHub stars and 4.97K GitHub forks.

According to the StackShare community, Python has a broader approval, being mentioned in 2830 company stacks & 3641 developers stacks; compared to Selenium, which is listed in 777 company stacks and 443 developer stacks.

What is Python?

Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.

What is Selenium?

Selenium automates browsers. That's it! What you do with that power is entirely up to you. Primarily, it is for automating web applications for testing purposes, but is certainly not limited to just that. Boring web-based administration tasks can (and should!) also be automated as well.
Get Advice Icon

Need advice about which tool to choose?Ask the StackShare community!

Why do developers choose Python?
Why do developers choose Selenium?

Sign up to add, upvote and see more prosMake informed product decisions

    Be the first to leave a con

    Sign up to add, upvote and see more consMake informed product decisions

    Jobs that mention Python and Selenium as a desired skillset
    What companies use Python?
    What companies use Selenium?

    Sign up to get full access to all the companiesMake informed product decisions

    What tools integrate with Python?
    What tools integrate with Selenium?

    Sign up to get full access to all the tool integrationsMake informed product decisions

    What are some alternatives to Python and Selenium?
    Java
    Java is a programming language and computing platform first released by Sun Microsystems in 1995. There are lots of applications and websites that will not work unless you have Java installed, and more are created every day. Java is fast, secure, and reliable. From laptops to datacenters, game consoles to scientific supercomputers, cell phones to the Internet, Java is everywhere!
    R
    R provides a wide variety of statistical (linear and nonlinear modelling, classical statistical tests, time-series analysis, classification, clustering, ...) and graphical techniques, and is highly extensible.
    JavaScript
    JavaScript is most known as the scripting language for Web pages, but used in many non-browser environments as well such as node.js or Apache CouchDB. It is a prototype-based, multi-paradigm scripting language that is dynamic,and supports object-oriented, imperative, and functional programming styles.
    Scala
    Scala is an acronym for “Scalable Language”. This means that Scala grows with you. You can play with it by typing one-line expressions and observing the results. But you can also rely on it for large mission critical systems, as many companies, including Twitter, LinkedIn, or Intel do. To some, Scala feels like a scripting language. Its syntax is concise and low ceremony; its types get out of the way because the compiler can infer them.
    Anaconda
    A free and open-source distribution of the Python and R programming languages for scientific computing, that aims to simplify package management and deployment. Package versions are managed by the package management system conda.
    See all alternatives
    Decisions about Python and Selenium
    StackShare Editors
    StackShare Editors
    Kubernetes
    Kubernetes
    Go
    Go
    Python
    Python

    Following its migration from vanilla instances with autoscaling groups to Kubernetes, Postmates began facing challenges while “migrating workloads that needed to scale up very quickly.”

    The built-in Horizontal Pod Autoscaler (HPA) automatically scales the number of pods in a replication controller, deployment or replica set based on observed CPU utilization. But the challenges for Postmates is that there’s no way to configure the scale velocity of one particular cluster with an HPA.

    For Postmates, which runs at least three different types of applications with distinct performance and scaling characteristics, this proved problematic.

    To overcome these challenges, the team created and open sourced the Configurable Horizontal Pod Autoscaler, which allows for fine-grained tuning on a per-HPA object basis. The result is that “you can configure critical services to scale down very slowly, while every other service could be configured to scale down instantly to reduce costs.”

    See more
    Hampton Catlin
    Hampton Catlin
    VP of Engineering at Rent The Runway · | 6 upvotes · 8.1K views
    atRent the RunwayRent the Runway
    Java
    Java
    Python
    Python
    Ruby
    Ruby

    At our company, and I've noticed a lot of other ones... application developers and dev-ops people tend to use Ruby and our statisticians and data scientists love Python . Like most companies, our stack is kind of split that way. Ruby is used as glue in most of our production systems ( Java being the main backend language), and then all of our data scientists and their various pipelines tend towards Python

    See more
    Ajit Parthan
    Ajit Parthan
    CTO at Shaw Academy · | 3 upvotes · 5.2K views
    atShaw AcademyShaw Academy
    Python
    Python
    PHP
    PHP
    #Etl

    Multiple systems means there is a requirement to cart data across them.

    Started off with Talend scripts. This was great as what we initially had were PHP/Python script - allowed for a more systematic approach to ETL.

    But ended up with a massive repository of scripts, complex crontab entries and regular failures due to memory issues.

    Using Stitch or similar services is a better approach: - no need to worry about the infrastructure needed for the ETL processes - a more formal mapping of data from source to destination as opposed to script developer doing his/her voodoo magic - lot of common sources and destination integrations are already builtin and out of the box

    etl @{etlasaservice}|topic:1323|

    See more
    SVN (Subversion)
    SVN (Subversion)
    Git
    Git
    JSON
    JSON
    XML
    XML
    Python
    Python
    PHP
    PHP
    Java
    Java
    Swift
    Swift
    JavaScript
    JavaScript
    Linux
    Linux
    GitHub
    GitHub
    Visual Studio Code
    Visual Studio Code

    I use Visual Studio Code because at this time is a mature software and I can do practically everything using it.

    • It's free and open source: The project is hosted on GitHub and it’s free to download, fork, modify and contribute to the project.

    • Multi-platform: You can download binaries for different platforms, included Windows (x64), MacOS and Linux (.rpm and .deb packages)

    • LightWeight: It runs smoothly in different devices. It has an average memory and CPU usage. Starts almost immediately and it’s very stable.

    • Extended language support: Supports by default the majority of the most used languages and syntax like JavaScript, HTML, C#, Swift, Java, PHP, Python and others. Also, VS Code supports different file types associated to projects like .ini, .properties, XML and JSON files.

    • Integrated tools: Includes an integrated terminal, debugger, problem list and console output inspector. The project navigator sidebar is simple and powerful: you can manage your files and folders with ease. The command palette helps you find commands by text. The search widget has a powerful auto-complete feature to search and find your files.

    • Extensible and configurable: There are many extensions available for every language supported, including syntax highlighters, IntelliSense and code completion, and debuggers. There are also extension to manage application configuration and architecture like Docker and Jenkins.

    • Integrated with Git: You can visually manage your project repositories, pull, commit and push your changes, and easy conflict resolution.( there is support for SVN (Subversion) users by plugin)

    See more
    Ajit Parthan
    Ajit Parthan
    CTO at Shaw Academy · | 1 upvotes · 4K views
    atShaw AcademyShaw Academy
    Python
    Python
    PHP
    PHP

    Multiple systems means there is a requirement to cart data across them.

    Started off with Talend scripts. This was great as what we initially had were PHP/Python script - allowed for a more systematic approach to ETL.

    But ended up with a massive repository of scripts, complex crontab entries and regular failures due to memory issues.

    Using Stitch or similar services is a better approach: - no need to worry about the infrastructure needed for the ETL processes - a more formal mapping of data from source to destination as opposed to script developer doing his/her voodoo magic - lot of common sources and destination integrations are already builtin and out of the box

    See more
    Eric Colson
    Eric Colson
    Chief Algorithms Officer at Stitch Fix · | 19 upvotes · 261.2K views
    atStitch FixStitch Fix
    Amazon EC2 Container Service
    Amazon EC2 Container Service
    Docker
    Docker
    PyTorch
    PyTorch
    R
    R
    Python
    Python
    Presto
    Presto
    Apache Spark
    Apache Spark
    Amazon S3
    Amazon S3
    PostgreSQL
    PostgreSQL
    Kafka
    Kafka
    #Data
    #DataStack
    #DataScience
    #ML
    #Etl
    #AWS

    The algorithms and data infrastructure at Stitch Fix is housed in #AWS. Data acquisition is split between events flowing through Kafka, and periodic snapshots of PostgreSQL DBs. We store data in an Amazon S3 based data warehouse. Apache Spark on Yarn is our tool of choice for data movement and #ETL. Because our storage layer (s3) is decoupled from our processing layer, we are able to scale our compute environment very elastically. We have several semi-permanent, autoscaling Yarn clusters running to serve our data processing needs. While the bulk of our compute infrastructure is dedicated to algorithmic processing, we also implemented Presto for adhoc queries and dashboards.

    Beyond data movement and ETL, most #ML centric jobs (e.g. model training and execution) run in a similarly elastic environment as containers running Python and R code on Amazon EC2 Container Service clusters. The execution of batch jobs on top of ECS is managed by Flotilla, a service we built in house and open sourced (see https://github.com/stitchfix/flotilla-os).

    At Stitch Fix, algorithmic integrations are pervasive across the business. We have dozens of data products actively integrated systems. That requires serving layer that is robust, agile, flexible, and allows for self-service. Models produced on Flotilla are packaged for deployment in production using Khan, another framework we've developed internally. Khan provides our data scientists the ability to quickly productionize those models they've developed with open source frameworks in Python 3 (e.g. PyTorch, sklearn), by automatically packaging them as Docker containers and deploying to Amazon ECS. This provides our data scientist a one-click method of getting from their algorithms to production. We then integrate those deployments into a service mesh, which allows us to A/B test various implementations in our product.

    For more info:

    #DataScience #DataStack #Data

    See more
    Python
    Python
    Django
    Django
    JavaScript
    JavaScript
    Node.js
    Node.js

    Django or NodeJS? Hi, I’m thinking about which software I should use for my web-app. What about Node.js or Django for the back-end? I want to create an online preparation course for the final school exams in my country. At the beginning for maths. The course should contain tutorials and a lot of exercises of different types. E.g. multiple choice, user text/number input and drawing tasks. The exercises should change (different levels) with the learning progress. Wrong questions should asked again with different numbers. I also want a score system and statistics. So far, I have got only limited web development skills. (some HTML, CSS, Bootstrap and Wordpress). I don’t know JavaScript or Python.

    Possible pros for Python / Django: - easy syntax, easier to learn for me as a beginner - fast development, earlier release - libraries for mathematical and scientific computation

    Possible pros for JavaScript / Node.js: - great performance, better choice for real time applications: user should get the answer for a question quickly

    Which software would you use in my case? Are my arguments for Python/NodeJS right? Which kind of database would you use?

    Thank you for your answer!

    Node.js JavaScript Django Python

    See more
    Git
    Git
    Docker
    Docker
    NATS
    NATS
    JavaScript
    JavaScript
    TypeScript
    TypeScript
    PostgreSQL
    PostgreSQL
    Python
    Python
    Go
    Go

    Go is a high performance language with simple syntax / semantics. Although it is not as expressive as some other languages, it's still a great language for backend development.

    Python is expressive and battery-included, and pre-installed in most linux distros, making it a great language for scripting.

    PostgreSQL: Rock-solid RDBMS with NoSQL support.

    TypeScript saves you from all nonsense semantics of JavaScript , LOL.

    NATS: fast message queue and easy to deploy / maintain.

    Docker makes deployment painless.

    Git essential tool for collaboration and source management.

    See more
    Omar Melendrez
    Omar Melendrez
    Front-end developer · | 3 upvotes · 4.2K views
    Python
    Python
    C#
    C#
    Node.js
    Node.js
    React
    React
    Vue.js
    Vue.js
    #Vscode
    #Fullstack

    I'm #Fullstack here and work with Vue.js, React and Node.js in some projects but also C# for other clients. Also started learning Python. And all this with just one tool!: #Vscode I have used Atom and Sublime Text in the past and they are very good too, but for me now is just vscode. I think the combination of vscode with the free available extensions that the community is creating makes a powerful tool and that's why vscode became the most popular IDE for software development. You can match it to your own needs in a couple of minutes. Did I mention you can style it your way? Amazing tool!

    See more
    Tom Klein
    Tom Klein
    CEO at Gentlent · | 4 upvotes · 28.7K views
    atGentlentGentlent
    Python
    Python
    Electron
    Electron
    Socket.IO
    Socket.IO
    Google Compute Engine
    Google Compute Engine
    TypeScript
    TypeScript
    ES6
    ES6
    Ubuntu
    Ubuntu
    PostgreSQL
    PostgreSQL
    React
    React
    nginx
    nginx
    Sass
    Sass
    HTML5
    HTML5
    PHP
    PHP
    Node.js
    Node.js
    JavaScript
    JavaScript

    Our most used programming languages are JavaScript / Node.js for it's lightweight and fast use, PHP because everyone knows it, HTML5 because you can't live without it and Sass to write great CSS. Occasionally, we use nginx as a web server and proxy, React for our UX, PostgreSQL as fast relational database, Ubuntu as server OS, ES6 and TypeScript for Node, Google Compute Engine for our infrastructure, and Socket.IO and Electron for specific use cases. We also use Python for some of our backends.

    See more
    Benjamin Poon
    Benjamin Poon
    QA Manager - Engineering at HBC Digital · | 7 upvotes · 46.1K views
    PostgreSQL
    PostgreSQL
    React
    React
    ExpressJS
    ExpressJS
    Docker
    Docker
    GoCD
    GoCD
    GitHub
    GitHub
    Cucumber
    Cucumber
    JavaScript
    JavaScript
    Selenium
    Selenium
    Nightwatchjs
    Nightwatchjs

    For our digital QA organization to support a complex hybrid monolith/microservice architecture, our team took on the lofty goal of building out a commonized UI test automation framework. One of the primary requisites included a technical minimalist threshold such that an engineer or analyst with fundamental knowledge of JavaScript could automate their tests with greater ease. Just to list a few: - Nightwatchjs - Selenium - Cucumber - GitHub - Go.CD - Docker - ExpressJS - React - PostgreSQL

    With this structure, we're able to combine the automation efforts of each team member into a centralized repository while also providing new relevant metrics to business owners.

    See more
    Praveen Mooli
    Praveen Mooli
    Technical Leader at Taylor and Francis · | 11 upvotes · 152.3K views
    MongoDB Atlas
    MongoDB Atlas
    Amazon S3
    Amazon S3
    Amazon DynamoDB
    Amazon DynamoDB
    Amazon RDS
    Amazon RDS
    Serverless
    Serverless
    Docker
    Docker
    Terraform
    Terraform
    Travis CI
    Travis CI
    GitHub
    GitHub
    RxJS
    RxJS
    Angular 2
    Angular 2
    AWS Lambda
    AWS Lambda
    Amazon SQS
    Amazon SQS
    Amazon SNS
    Amazon SNS
    Amazon Kinesis Firehose
    Amazon Kinesis Firehose
    Amazon Kinesis
    Amazon Kinesis
    Flask
    Flask
    Python
    Python
    ExpressJS
    ExpressJS
    Node.js
    Node.js
    Spring Boot
    Spring Boot
    Java
    Java
    #Data
    #Devops
    #Webapps
    #Eventsourcingframework
    #Microservices
    #Backend

    We are in the process of building a modern content platform to deliver our content through various channels. We decided to go with Microservices architecture as we wanted scale. Microservice architecture style is an approach to developing an application as a suite of small independently deployable services built around specific business capabilities. You can gain modularity, extensive parallelism and cost-effective scaling by deploying services across many distributed servers. Microservices modularity facilitates independent updates/deployments, and helps to avoid single point of failure, which can help prevent large-scale outages. We also decided to use Event Driven Architecture pattern which is a popular distributed asynchronous architecture pattern used to produce highly scalable applications. The event-driven architecture is made up of highly decoupled, single-purpose event processing components that asynchronously receive and process events.

    To build our #Backend capabilities we decided to use the following: 1. #Microservices - Java with Spring Boot , Node.js with ExpressJS and Python with Flask 2. #Eventsourcingframework - Amazon Kinesis , Amazon Kinesis Firehose , Amazon SNS , Amazon SQS, AWS Lambda 3. #Data - Amazon RDS , Amazon DynamoDB , Amazon S3 , MongoDB Atlas

    To build #Webapps we decided to use Angular 2 with RxJS

    #Devops - GitHub , Travis CI , Terraform , Docker , Serverless

    See more
    PubNub
    PubNub
    asyncio
    asyncio
    JavaScript
    JavaScript
    Python
    Python

    I love Python and JavaScript . You can do the same JavaScript async operations in Python by using asyncio. This is particularly useful when you need to do socket programming in Python. With streaming sockets, data can be sent or received at any time. In case your Python program is in the middle of executing some code, other threads can handle the new socket data. Libraries like asyncio implement multiple threads, so your Python program can work in an asynchronous fashion. PubNub makes bi-directional data streaming between devices even easier.

    See more
    Kevin Roulleau
    Kevin Roulleau
    QA Engineer Freelance at happn · | 5 upvotes · 13.3K views
    athappnhappn
    Selenium
    Selenium
    Appium
    Appium
    WebdriverIO
    WebdriverIO

    I chose WebdriverIO and Appium to implement a E2E tests solution on a native mobile app. WebdriverIO goes well beyond just implementing the Selenium / Appium protocol and allows to run tests in parallel out of the box. Appium has the big advantage of supporting iOS and Android platforms, so the test codebase and tools are exactly the same, which greatly reduces the learning curve and implementation time.

    See more
    Helio Junior
    Helio Junior
    CSS 3
    CSS 3
    JavaScript
    JavaScript
    Python
    Python
    #Electron
    #NodeJS
    #UXdesign
    #DataScience

    Python is a excellent tool for #DataScience , but up to now is very poor in #uxdesign . To do some design I'm using JavaScript and #nodejs , #electron stack. The possibility of use CSS 3 to draw interfaces is very awesome and fast. Unfortunatelly Python don't have (yet) a good way to make a #UXdesign .

    See more
    Interest over time
    Reviews of Python and Selenium
    Review ofSeleniumSelenium

    we at www.cloudqa.io use selenium hub and node architecture to execute our test cases its a very powerful tool to automate web applications.

    How developers use Python and Selenium
    Avatar of Exchange rates API
    Exchange rates API uses PythonPython

    Beautiful is better than ugly.

    Explicit is better than implicit.

    Simple is better than complex.

    Complex is better than complicated.

    Flat is better than nested.

    Sparse is better than dense.

    Readability counts.

    Special cases aren't special enough to break the rules.

    Although practicality beats purity.

    Errors should never pass silently.

    Unless explicitly silenced.

    In the face of ambiguity, refuse the temptation to guess.

    There should be one-- and preferably only one --obvious way to do it.

    Although that way may not be obvious at first unless you're Dutch.

    Now is better than never.

    Although never is often better than right now.

    If the implementation is hard to explain, it's a bad idea.

    If the implementation is easy to explain, it may be a good idea.

    Namespaces are one honking great idea -- let's do more of those!

    Avatar of Web Dreams
    Web Dreams uses PythonPython

    To me, this is by far the best programming language. Why? Because it’s the only language that really got me going after trying to get into programming with Java for a while. Python is powerful, easy to learn, and gets you to unsderstand other languages more once you understand it. Did I state I love the python language? Well, I do..

    Avatar of ttandon
    ttandon uses PythonPython

    Backend server for analysis of image samples from iPhone microscope lens. Chose this because of familiarity. The number one thing that I've learned at hackathons is that work exclusively with what you're 100% comfortable with. I use Python extensively at my day job at Wit.ai, so it was the obvious choice for the bulk of my coding.

    Avatar of papaver
    papaver uses PythonPython

    been a pythoner for around 7 years, maybe longer. quite adept at it, and love using the higher constructs like decorators. was my goto scripting language until i fell in love with clojure. python's also the goto for most vfx studios and great for the machine learning. numpy and pyqt for the win.

    Avatar of Blood Bot
    Blood Bot uses PythonPython

    Large swaths of resources built for python to achieve natural language processing. (We are in the process of deprecating the services written in python and porting them over to Javascript and node)

    Avatar of Kang Hyeon Ku
    Kang Hyeon Ku uses SeleniumSelenium

    가장 강력한 웹 UI / UX 테스트 툴 이지만, 문제도 많다. iframe 안에 있는 건 잘 select 가 안되기도 하고, 화면이 작아 컴포넌트가 화면에 보이지 않으면 또 select 할 수 없다. 하지만 브라우저를 있는 그대로 제어 할 수 있다는 게 가장 큰 매력이다.

    ps. selenide 와 같이 쓰면 코드가 많이 개선된다.

    Avatar of samdfonseca
    samdfonseca uses SeleniumSelenium

    Maintaining and expanding automated regression tests is one of my primary responsibilities at CrowdTwist. We use Selenium to test the front-end parts of our platform.

    Avatar of Ralic Lo
    Ralic Lo uses SeleniumSelenium

    Used Selenium web-driver for automated QA testing in continuous integration and continuous deployment.

    Avatar of Owen Miller
    Owen Miller uses SeleniumSelenium
    • Navigating our site for tests
    • Navigating other sites that discriminate against non-human visitors
    Avatar of Ataccama
    Ataccama uses SeleniumSelenium

    Selenium is a great way to automatically test if a build is sane and can be deployed.

    How much does Python cost?
    How much does Selenium cost?
    Pricing unavailable
    Pricing unavailable