# Alert user based on' GeoFences'

**URL:** <https://community.qfield.org/t/alert-user-based-on-geofences/422>\
**Category:** Ask the Community\
**Tags:** gh-import\
**Created:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422 "2025-05-14T02:17:14Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/1 "2025-05-14T02:17:14Z")

</div>

One thing that would be really helpful for fieldwork with QField is the ability to designate layers as ‘geofences’:  
i.e. a hazard point layer is included in the Qfield project, alert the user when they get within xx meters of a hazard.  
or a polygon layer is included in the project representing restricted/no-go areas. Qfield app alerts the user when they enter the area.

* * *

_Imported from [GitHub discussion](https://github.com/opengisch/qfield/discussions/3708) by @timbo-barnes on 2022-11-30T00:41:09Z_

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/2 "2025-05-14T02:17:15Z")

</div>

Thanks for the suggestion. This feature is unlikely to be developed in QField without financial support for it, if you are interested please drop us an email on info at opengis.ch.

In the meantime, I believe with some ninja skills in QGIS expressions you can make the screen to blink and flash whenever the condition you mentioned is satisfied.

* * *

_Imported from [GitHub comment](https://github.com/opengisch/QField/discussions/3708#discussioncomment-4302882) by @suricactus on 2022-12-04T11:27:39Z_

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/3 "2025-05-14T02:17:16Z")

</div>

Note that geofences are available in Mergin Input

> **[Mergin Maps Version 1.0 Release | New Features & Enhancements](https://www.lutraconsulting.co.uk/blogs/input-version-1-0-release)**
>
> Discover the exciting new features in Mergin Maps version 1.0. Enjoy improved functionality for mobile data collection, seamless syncing, and enhanced collaboration for field mapping projects.

and are an open enhancement in QGIS

> <https://github.com/qgis/QGIS-Enhancement-Proposals/issues/217>
>
> \# QGIS Enhancement: Integrate GPS Tools plugin functionality into core QGIS
> 
> \*…\*Date\*\* 2021/03/19
> 
> \*\*Author\*\* Nyall Dawson (@nyalldawson)
> 
> \*\*Contact\*\* nyall dot dawson at gmail dot com
> 
> \*\*Version\*\* QGIS 3.22 or earlier
> 
> \# Summary
> 
> Since QGIS 3.0, an ongoing effort has been underway to reduce the number of "core plugins". (These are plugins which are shipped with the default QGIS install, but inactive by default.) These plugins are undesirable for a number of reasons:
> 
> \- the code is "siloed" away from the main QGIS codebase, and consequently these plugins are very poorly maintained
> \- the plugin functionality is not integrated well into the QGIS application (e.g. the functionality is present only in a single dialog, and not available via Processing, the unified Data Source Manager, the global QGIS settings dialog, etc), and follows different UI conventions to the rest of QGIS
> \- the plugin functionality is not available via PyQGIS, so third party plugins and scripts cannot take advantage of the features
> \- an inconsistent user experience -- because the plugins are not enabled by default, the features available in different installations of QGIS can vary between different QGIS installs (depending on whether or not a user has manually enabled the plugin). This leads to user confusion and frustration, as buttons and menus which are present on "their" QGIS install are not available on another QGIS install for unclear reasons.
> 
> (see https://github.com/qgis/qgis4.0\_api/issues/67 for further details)
> 
> This proposal covers removing the "GPS Tools" core plugin, and integrating its functionality with the main QGIS application.
> 
> \## Proposed Solution
> 
> When enabled, the GPS tools plugin exposes all functionality through a single tabbed dialog:
> !\[image\](https://user-images.githubusercontent.com/1829991/111711660-f6fac180-8897-11eb-85e2-80e9aa5c9840.png)
> 
> This dialog mixes several different functions:
> 
> 1. Adding data to a project (via the "Load GPX file" tab, the "Import other file" tab, and "Download from GPS" tab.). See below:
> !\[image\](https://user-images.githubusercontent.com/1829991/111711785-31645e80-8898-11eb-8c23-3c1f229fbfd7.png)
> 
> !\[image\](https://user-images.githubusercontent.com/1829991/111711821-3d502080-8898-11eb-8cc0-522ff17f0a67.png)
> 
> !\[image\](https://user-images.githubusercontent.com/1829991/111711838-45a85b80-8898-11eb-821f-a0d6a6bfe686.png)
> 
> 2. Management of GPS devices:
> !\[image\](https://user-images.githubusercontent.com/1829991/111711887-5c4eb280-8898-11eb-9b91-fb40c44c7d97.png)
> 
> 3. Upload to GPS:
> !\[image\](https://user-images.githubusercontent.com/1829991/111711954-78eaea80-8898-11eb-8dbf-671d2ae20c5f.png)
> 
> 4. GPX conversions:
> !\[image\](https://user-images.githubusercontent.com/1829991/111711984-84d6ac80-8898-11eb-820e-98804dc746b0.png)
> 
> It is proposed that the functionality be integrated into QGIS by the following approach:
> 
> \### "Add data" functionality
> 
> The features for adding data from the "Load GPX file", "Import other file" and "Download from GPS" tabs will be moved to a new "GPS" tab in unified QGIS Data Source Manager (See below):
> 
> !\[image\](https://user-images.githubusercontent.com/1829991/111712157-ccf5cf00-8898-11eb-94a2-b92ab5602572.png)
> 
> The Data Source Manager was designed as a all-encompassing approach for users to add data to a QGIS project, so moving the GPS tools "add data" functions into this dialog is a natural fit, and will help expose this functionality to a wider range of users and provide a more discoverable place for this functionality to reside.
> 
> \### GPS Device Management
> 
> This functionality will be moved to a new "GPS Devices" tab in the main QGIS settings - Options dialog. This dialog is the normal place for all QGIS user-editable settings to reside, and again is a natural place for users to look when configuring GPS devices.
> 
> The main options dialog offers improved user experience, e.g. it offers the ability for users to search easily for settings across all tabs.
> 
> \### Upload to GPS/GPX conversions
> 
> These two features are "data management" style operations, and should be moved to the Processing framework accordingly. By exposing this functionality as Processing algorithms we offer users many benefits:
> 
> \- A standard UI and approach for running the tools
> \- The ability to run the tools as batch processes or within models
> \- Third party scripts and plugins can easily call the functionality without having to reimplement it themselves.
> 
> \### Affected Files
> 
> Classes from the GPS Tools plugin will be separated and moved to the core, analysis or app libraries as required. The c++ plugin code will then be removed.
> 
> \## Performance Implications
> 
> None
> 
> \## Further Considerations/Improvements
> 
> Users will be notified via the release notes/changelog of the moved plugin functionality.

* * *

_Imported from [GitHub comment](https://github.com/opengisch/QField/discussions/3708#discussioncomment-10503891) by @ntrip6 on 2024-08-30T21:12:40Z_

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/4 "2025-05-14T02:17:18Z")

</div>

Geofencing has been implemented and will be available in the next version of QField (3.4). The PRs covering the implementation is [Implementation of geofencing functionality by nirvn · Pull Request #5409 · opengisch/QField · GitHub](https://github.com/opengisch/QField/pull/5409) . The implementation includes a visual warnings when entering / leaving a geofenced area as well as a digitizing prohibition when in or out of geofenced areas. Pretty exciting functionality! 🙂

* * *

_Imported from [GitHub comment](https://github.com/opengisch/QField/discussions/3708#discussioncomment-10504881) by @nirvn on 2024-08-31T02:28:43Z_

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/5 "2025-05-14T02:17:19Z")

</div>

ntrip6 , the geofences hack you are referring to with input is something QField has also supported for years. The relevant variables to build the default value expression are listed in QField’s documentation site here ([Positioning (GNSS) - QField Ecosystem Documentation](https://docs.qfield.org/how-to/gnss/#positioning-variables)). That’s however a limited workaround and doesn’t offer any visual indication _prior to_ getting to a feature form, which is partly why I’m excited about upcoming QField 3.4’s geofencing functionality.

* * *

_Imported from [GitHub comment](https://github.com/opengisch/QField/discussions/3708#discussioncomment-10504888) by @nirvn on 2024-08-31T02:32:14Z_

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/flex018/uploads/qfield/original/1X/7d3726da0ef5099a1e135505c03d2f125d527aae.png) [@system](https://community.qfield.org/u/system)\
**Post date:** [14 May 2025 02:17 UTC](https://community.qfield.org/t/alert-user-based-on-geofences/422/6 "2025-05-14T02:17:21Z")

</div>

Fantastic, thanks QField team 🙂

* * *

_Imported from [GitHub comment](https://github.com/opengisch/QField/discussions/3708#discussioncomment-10630842) by @timbo-barnes on 2024-09-12T21:15:19Z_
