Back to Portfolio

Sydney Airbnb Market Analysis - SQL Skills Demonstration

Comprehensive SQL-based analysis of Sydney's Airbnb market demonstrating advanced database querying, data exploration, and business insight generation. Uncovered pricing patterns, neighborhood insights, and actionable improvement opportunities for hosts.

Key Insights

Total Listings

14,274

Active Airbnb properties analyzed

Unique Hosts

7,823

Individual hosts managing properties

Most Expensive

Pittwater

$958/night average price

Dominant Type

79% Entire Homes

11,287 of total listings

Price Range

$115 - $958

Shared rooms to luxury homes

Business Opportunity

Cleaning Services

Hosts with 'dirty' complaints identified

SQL Analysis Workflow

1. Database Setup & Data Loading

Setting up SQLite database, loading CSV data into tables, and establishing the foundation for SQL analysis.

import sqlite3
import pandas as pd

# Load the dataset
df = pd.read_csv('listings.csv')

# Create SQLite database connection
conn = sqlite3.connect('mytable.db')

# Save dataframe as SQL table
df.to_sql(name="listings", con=conn, if_exists='replace', index=False)

# Commit changes
conn.commit()

# Connect to database for SQL queries
%load_ext sql
%sql sqlite:///mytable.db

Database Connection Result:

Connected: @mytable.db
Table 'listings' created successfully
14274 rows loaded
Complete
Data Setup
SQLite database ready for analysis
listings
Table Created
Main dataset loaded successfully
Active
Connection
Ready for SQL queries

2. Market Overview & Room Types

Exploring the basic structure of Sydney's Airbnb market, including room types, total listings, and host distribution.

-- Explore different room types available
SELECT DISTINCT room_type
FROM listings;

-- Count total listings
SELECT COUNT(DISTINCT id) as total_listings
FROM listings;

-- Room type distribution
SELECT DISTINCT room_type, count(room_type) as listing_count
FROM listings
GROUP BY room_type;

Room Types Available:

Private room
Entire home/apt
Shared room
Hotel room

Room Type Distribution:

Room TypeCount
Entire home/apt11,287
Private room2,823
Shared room91
Hotel room73
4 Categories
Room Types
Entire home, Private, Shared, Hotel
1.8:1
Host Ratio
Listings per host average
14,274
Market Size
Total active listings

3. Pricing Analysis by Room Type

Analyzing average prices and review patterns across different room types to understand market positioning and guest preferences.

-- Average price and reviews by room type
SELECT DISTINCT room_type, 
       count(room_type) as listing_count,
       ROUND(avg(price), 2) as avg_price,
       ROUND(avg(number_of_reviews), 1) as avg_reviews
FROM listings
GROUP BY room_type
ORDER BY avg_price DESC;

Pricing & Review Analysis:

Room TypeCountAvg PriceAvg Reviews
Entire home/apt11,287$464.2936.8
Hotel room73$299.90101.6
Private room2,823$134.3127.1
Shared room91$115.997.1
$464/night
Entire Home/Apt
Most expensive category
101 reviews
Hotel Rooms
Highest review frequency
4x Premium
Price Difference
Entire homes vs shared rooms

4. Neighborhood Analysis & Market Segmentation

Deep dive into neighborhood pricing patterns, host concentration, and market dynamics across Sydney's diverse areas.

-- Top 10 most expensive neighborhoods
SELECT DISTINCT neighbourhood, 
       count(id) as listing_count,
       ROUND(avg(price), 2) as avg_price,
       count(distinct host_id) as unique_hosts
FROM listings
GROUP BY neighbourhood
ORDER BY avg_price DESC
LIMIT 10;

Top 10 Most Expensive Neighborhoods:

NeighborhoodListingsAvg PriceHosts
Pittwater901$958.36592
Woollahra449$688.73311
Mosman191$539.48135
Manly651$491.71483
Waverley1,319$480.03815
... 33 more neighborhoods
$958/night
Pittwater
Most expensive neighborhood
901 listings
Host Concentration
592 hosts in Pittwater
38 Areas
Market Spread
Diverse neighborhood coverage

5. Property Mix Analysis by Location

Examining the composition of property types across neighborhoods to identify market positioning and opportunities.

-- Property type percentages by neighborhood (top 10)
SELECT neighbourhood,
    ROUND((COUNT(CASE WHEN room_type = 'Entire home/apt' THEN 1 END) * 100.0 / COUNT(*)),1) AS pct_entire_home,
    ROUND((COUNT(CASE WHEN room_type = 'Private room' THEN 1 END) * 100.0 / COUNT(*)),1) AS pct_private_room
FROM listings
GROUP BY neighbourhood
ORDER BY pct_entire_home DESC
LIMIT 10;

Property Mix by Neighborhood (Top 10):

Neighborhood% Entire Home% Private Room
Pittwater95.1%4.7%
Manly92.9%7.1%
Mosman91.1%8.9%
Sutherland Shire89.6%9.9%
Warringah89.1%10.8%
... vs Bankstown: 43.7% entire homes, 55.7% private rooms
95.1%
Pittwater
Entire homes dominate luxury areas
55.7%
Bankstown
Private rooms in outer suburbs
Room Mix
Market Opportunity
Diversification potential identified

6. Review Analysis & Business Improvement Opportunities

Analyzing guest reviews to identify specific improvement opportunities for hosts, focusing on cleanliness issues as a concrete business case.

-- Load reviews data and join with listings
-- Find hosts with cleanliness complaints
SELECT host_id, host_name, name, 
       SUBSTR(comments, 1, 100) || '...' as comment_preview
FROM reviews 
INNER JOIN listings ON listings.id = reviews.listing_id
WHERE comments LIKE '%dirty%'
LIMIT 5;

Hosts with Cleanliness Issues (Sample):

HostPropertyIssue Preview
MirkoSydney CBD ApartmentPlace was dirty upon arrival, floors dirty...
TonyPittwater Boat HouseProperty not cleaned, kitchen/bathroom dirty...
JohnMosman StudioFound it a bit too dirty, not cleaned well...
+ Multiple other hosts identified
Business Opportunity: Specific hosts identified for cleaning service outreach
Cleaning Services
Improvement Opportunity
Multiple hosts with dirty complaints
Actionable
Business Case
Specific hosts identified for outreach
Evidence-Based
Data-Driven
Review analysis supports recommendations

Business Applications & Insights

For Property Investors

Pittwater emerges as the premium market with $958/night average, while areas like Bankstown offer opportunities in the private room segment with 55.7% market share.

For Airbnb Hosts

Entire homes command 4x premium over shared rooms ($464 vs $115/night). Hotel rooms generate highest review frequency (101 avg), indicating strong guest engagement.

For Service Providers

Analysis identified specific hosts with cleanliness complaints, presenting concrete business opportunities for cleaning services and property management companies.

SQL Skills Demonstrated

SQLSQLite3PythonPandasJupyter NotebookData AnalysisBusiness Intelligence

Key SQL Techniques

  • Complex INNER JOINs across multiple tables
  • Advanced GROUP BY with aggregations
  • CASE statements for conditional logic
  • Text pattern matching with LIKE
  • Statistical functions and calculations

Technologies Used

SQLSQLite3PythonPandasJupyter NotebookData AnalysisBusiness Intelligence

Project Links

This project showcases SQL analysis skills and business intelligence capabilities.