JST --:--:--

Granny Flat Company

Granny flat builder website

A website for a range of six granny flats from Marksman Build, a building company in Selwyn, Canterbury, New Zealand. Each design can be read as a floor plan, seen from above or turned around in 3D, and then placed on an aerial photo of your own section to see if it fits.

Visit Live Site arrow_outward
Granny Flat Company homepage: a heading about adding a granny flat for family, beside a photo of a family at a backyard picnic table
9:41
Granny Flat Company homepage on a phone
6 Designs, from one to three bedrooms
3 Ways to see each one: plan, top view and 3D
1:100 Scale every floor plan was checked at
The problem

A granny flat is a big decision about a small space. Before anyone picks up the phone they want to know two things: what it is like inside, and whether it will actually fit in their backyard. A price list and a few photos can’t answer either.

Top highlights

Our designs page: bedroom filter tabs and a grid of design tiles, each with a floor plan drawn to the same scale
1

Six designs, drawn to one scale

From a one-bedroom studio to a three-bedroom family home, every design sits in the same grid at the same scale, so a bigger plan really looks bigger. Filter by bedrooms, sort by size, and hover a tile to swap its floor plan for a 3D view from above.

The Family design page: a large floor plan with dimension lines beside the design’s specifications
2

Floor plans checked at 1:100

The plans come from the builder’s own drawing set. Each one was checked at 1:100 against the footprint on the sheet, and the room sizes on every page are copied from the drawings, never recalculated. Under the plan sit the concept drawings: section and elevations, opened full size with a tap.

The same design as a 3D model seen from a corner, with furnished rooms and the walls cut away
3

Plan, top view or 3D model

A switch on each design page moves between the drawn plan, a cutaway view from above and a 3D model you can turn with a finger. The views are built from the same drawings, so the walls, doors and windows are where the plan puts them. The furniture is only there to give a sense of size, and the page says so.

Measure it: a granny flat floor plan placed and turned on an aerial photo of a paddock, with rotation controls beside the map
4

Measure it: try it on your own section

Type your address, pick a design, and the plan appears on an aerial photo of your property at true size. Drag it into place, turn it with a handle or a slider, and tap two points to measure a distance. It checks the address is in Canterbury, says plainly that it is a guide and not a survey, and a placement can be shared as a link or sent with an enquiry.

Contact form with name, email, phone, property address and topic fields, opened from a design page
5

Enquiries that arrive with the details

“Ask about this design” opens the contact form with that design already chosen, and an enquiry from Measure it brings the address and the exact placement with it. The builder knows which home and which section they are talking about before calling back.

9:41
A design page on a phone: the floor plan with zoom buttons above the design name
6

Made for a phone in the backyard

Plenty of people will look at this standing on their own section. Plans pinch to zoom, the 3D model turns with a finger, the map controls are big enough for a thumb, and the phone number is one tap away on every page.

Behind the site, for the builder

Every placement on a map

In the admin, a Measure it enquiry shows the granny flat where the visitor put it, next to their message, status and notes.

Prices changed without a developer

The owner can update a design’s price or hide a design from the admin, and every page picks up the change within a minute.

Visitors counted without cookies

Page views, clicks and referral links in one place, with no cookies and no stored IP addresses, so no consent banner.

Project overview

Client
Granny Flat Company, a range of granny flats from Marksman Build Ltd, a building company based in Selwyn, Canterbury, New Zealand.
My role
Design and development of the whole website: the design pages, the top views and 3D models, Measure it, the enquiry flow, email and the admin.
Deliverables
  • Home, Getting started and Our team pages
  • Six design pages with plan, top view, 3D model and drawings
  • Measure it: place a design on an aerial photo of your section
  • Contact form that carries over the design and address
  • Enquiry emails, with optional confirmations sent from Gmail
  • Admin for enquiries, design prices, analytics and reports
Status
Live at grannyflatcompany.co.nz.

Build homes or run a trade business in Australia or New Zealand? See my websites for tradies.

Technical details for developers

Stack, architecture and how it is built.

Stack

Frontend
Next.js 16 (static export) React 19 TypeScript 5 Tailwind CSS v4 Motion
Maps
MapLibre GL JS Turf.js LINZ data Esri geocoding
3D
PyMuPDF Blender glTF model-viewer
Backend
Cloudflare Workers Cloudflare D1 Email Routing Gmail API Search Console API

Architecture

architecture

Plans read from the drawing set

A PyMuPDF script reads the vector drawing PDF and sorts every mark by colour, line weight and shape: walls, windows, sliding and hinged doors, benches, showers, beds. It fails loudly unless the footprint matches the design data within 2 cm and every room matches its printed area within 0.11 m². Blender then renders the top view from that geometry and exports the same scene as a glTF model, so the 2D plan, the top view and the 3D model can’t disagree.

straighten

A plan that stays to scale on the map

In Measure it the plan is not a picture laid over the map but a shape on the ground: Turf.js works out its four corners in latitude and longitude from the centre, width, depth and bearing, and MapLibre draws the plan image onto them, so zooming can never change its real size. Address search goes through the Worker so no key reaches the browser, and a point-in-polygon test against the Canterbury region boundary decides whether an address is in the service area. Property boundaries from LINZ are wired in; where no boundary is available, the tool says the placement is approximate. The whole state lives in the URL, so a refresh or a shared link opens the same placement.

dataset

One data file, with overrides from the admin

The six designs live in one TypeScript file that feeds the tiles, the design pages, Measure it, the contact form and the admin. The site is a static export, so every value is in the HTML for search engines. When the owner changes a price or hides a design in the admin, the change is saved in D1 and the pages apply it over the built-in values from a small cached endpoint, with no rebuild.

Highlights

save

Saved Before Emailed

Every enquiry is written to Cloudflare D1 first, then emailed through Cloudflare Email Routing, with a connected Gmail account as the fallback. If a send fails the enquiry is still there, and the admin settings say why.

lock

Locked-Down Admin

The admin password is stored only as a PBKDF2 hash, sessions are signed HttpOnly cookies, and changes must come from the site’s own origin. Gmail is connected with send-only access and its token is stored encrypted. Forms, sign-in and map lookups are rate-limited per IP.

Want something like this?

I build websites that answer a customer’s real questions before they call, with the enquiry tools a small business needs behind them.