Skip to content

Python class to scrape data from rightmove.co.uk and return listings in a pandas DataFrame object

License

Notifications You must be signed in to change notification settings

HarvsG/rightmove_floorscraper

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

61 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rightmove_webscraper

rightmove.co.uk is one of the UK's largest property listings websites, hosting thousands of listings of properties for sale and to rent.

rightmove_webscraper.py is a simple Python interface to scrape property listings from the website and prepare them in a Pandas dataframe for analysis.

Installation

Version 0.3 is now available as a package with all required dependencies on Pip.

Install with:

pip install -U rightmove-webscraper

How to use

  1. Go to rightmove.co.uk and search for whatever listings you are interested in ...

  1. Filter the search however you choose ...

  1. Run the search and copy the URL of the results page ...

  1. Create an instance of the class on the URL ...
from rightmove_webscraper import rightmove_data
url = "http://www.rightmove.co.uk/property-for-sale/find.html?locationIdentifier= [...] "
rightmove_object = rightmove_data(url)
  1. Access the data using the methods and attributes of the object ...

Find the average price of all listings returned by the search:

rightmove_object.average_price

Show the total number of listings returned by the search:

rightmove_object.results_count

Access the full results as a Pandas dataframe with the .get_results attribute.

rightmove_object.get_results

Get quick summary statistics of the results, showing the number of listings and average price grouped by the number of bedrooms:

rightmove_object.summary()

Alternatively group the results by any other column returned in the .get_results DataFrame, for example Postcode:

rightmove_object.summary(by = "postcode")

Legal

@toddy86 has pointed out per the terms and conditions here the use of webscrapers is unauthorised by rightmove. So please don't use this package!

About

Python class to scrape data from rightmove.co.uk and return listings in a pandas DataFrame object

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 80.8%
  • Python 19.2%