The spread of red palm weevil (RPW) infestation of palm trees is prevalent in many countries, causing tremendous economic losses estimated at multi-millions of dollars annually. The utilization of a swarm of multiple unmanned aerial vehicles (UAVs) with suitable equipment has the potential to support RPW detect and treat (DAT) missions. Nevertheless, this approach raises a challenge regarding the efficient distribution of UAVs during search and detect tasks within the constraints of a mission. This paper proposes a new autonomous bio-inspired approach for efficiently allocating tasks among multiple UAVs during DAT missions. The new approach is inspired by the autonomous behaviour of bacteria as they forage for food. The performance of the proposed algorithm was benchmarked against two long-standing multi-UAV task allocation paradigms: opportunistic task allocation and auction-based heuristics, which were thoroughly tested in simulated DAT mission scenarios to comparatively assess their performance. The experimental results demonstrated the superior performance of the proposed algorithm, as it detected more infestations at shorter runtimes. These results validate the high flexibility, scalability, and sustainability of the proposed approach.