Text Stamping British National Grid (BNG) Data onto QField Photos
In professional field surveying, a photo is often insufficient without verifiable spatial context. While standard mobile cameras store coordinates in EXIF metadata, many UK-based GIS workflows require British National Grid (BNG) Eastings and Northings to be visually "stamped" or burned into the image pixels for instant reporting. Using QField—the mobile companion for QGIS—you can automate this process. By leveraging QField's ability to handle expressions during the image-naming and attachment process, you can ensure every site photo carries its precise OSGB36 location, timestamp, and project ID directly on the visual record.
Table of Content
- Purpose of Visual Data Stamping
- Common Use Cases
- Step by Step: Configuring BNG Stamps
- Best Results for Field Audits
- FAQ
- Disclaimer
Purpose
The primary purpose of stamping BNG data onto photos is Visual Accountability. In sectors like environmental consultancy or civil engineering in the UK, stakeholders often need to view a PDF report where the photo clearly displays its EPSG:27700 coordinates without requiring a GIS specialist to extract EXIF data. This workflow bridges the gap between raw field captures and "ready-to-print" evidence, reducing the administrative burden of post-processing photos back in the office.
Use Case
In-app photo stamping is essential for:
- Asset Inspections: Stamping utility pole or manhole IDs along with Easting/Northing for maintenance logs.
- Ecological Surveys: Documenting species sightings where the specific BNG grid square must be visible for biodiversity records.
- Construction Monitoring: Providing time-stamped, georeferenced progress photos that comply with UK planning conditions.
- Legal Evidence: Creating a tamper-evident record of site conditions with a hard-coded spatial reference.
Step by Step
1. Prepare the Layer in QGIS
Open your project in QGIS and select the point layer where photos will be stored. Ensure you have a field (usually photo) set to the Attachment widget type.
- Set the "Storage Mode" to "Relative to Project Path".
- Configure the "Store path as" to "Plain Text".
2. Configure the QField Photo Naming Expression
QField allows you to use expressions to name the file. We can "fake" a stamp by including BNG data in the filename, but for a visual stamp, we need to utilize the QField "Annotation" or "Watermark" feature (available in modern QField versions).
- Navigate to the QField tab in the Layer Properties.
- Locate the Photo Watermarking section.
- Enable "Stamp information on captured images."
3. Insert the BNG Expression
In the watermark expression box, you need to transform the default WGS84 GPS coordinates into BNG. Use the following expression:
'BNG: ' || round(x(transform($geometry, 'EPSG:4326', 'EPSG:27700')), 0) || ', ' || round(y(transform($geometry, 'EPSG:4326', 'EPSG:27700')), 0)
This takes the point geometry, converts it to British National Grid, and rounds the Easting and Northing to the nearest meter.
4. Add Metadata and Timestamps
To maximize the utility of the stamp, append the date and time:
[% 'BNG: ' || round(x(transform($geometry, 'EPSG:4326', 'EPSG:27700')), 0) %] [% format_date(now(), 'dd/MM/yyyy HH:mm') %]
5. Deploy to QField
Sync your project via QFieldCloud or cable transfer. When you open the camera within QField and take a photo, the app will process the expression and overlay the resulting text onto the bottom corner of the .jpg file automatically.
Best Results
| Stamp Element | Recommended Syntax | Benefit |
|---|---|---|
| Grid Reference | EPSG:27700 Transform |
UK Standard Compliance |
| Accuracy | @horizontal_accuracy |
Provides confidence in the data |
| User ID | @qfield_username |
Audit trail for team projects |
FAQ
Why is the stamp showing 0,0?
This happens if the GPS hasn't achieved a fix yet. Ensure you have a "high accuracy" lock in QField before snapping the photo. You can add a conditional check to the expression to display "Waiting for GPS..." if the geometry is null.
Can I change the font color or size?
In current QField releases, the watermark style is largely determined by the app's default settings (usually white text with a slight shadow). To have full control over styling, you would need to use a post-processing Python script in QGIS after syncing data back.
Will the stamp work if I am offline?
Yes. The coordinate transformation between WGS84 and BNG is mathematical and does not require an active internet connection, provided the transformation parameters are included in your project.
Disclaimer
Hard-stamping data into an image is a destructive process; the text becomes part of the pixel data and cannot be removed later. Always ensure your EXIF data is also being saved as a backup. This tutorial is based on QField 3.x standards as of March 2026. Be aware that coordinate transformation accuracy (specifically the OSTN15 shift) may vary slightly depending on the grid shift files installed on your mobile device.
Tags: QField, BNG, FieldData, OSGB36
