To address challenges in uncrewed aerial vehicles (UAV) object detection including complex backgrounds, severe occlusion, dense small objects, and varying lighting conditions, we propose FDM-DETR, a novel detection algorithm specifically designed for small objects in UAV imagery. This method effectively captures global image information by fusing multi-scale spatial features and performing feature extraction in the frequency domain within the backbone network. We design a Dynamic Feature Interaction (DIFI) module with position-based biases in the encoder, enhancing the model’s perception of local features for small objects. In the neck network, we introduce a Multi-Scale Feature Enhancement Pyramid (MSFEP) module to improve feature extraction capabilities for small object detection. Compared to RT-DETR, our improved model achieves performance gains of 2.5% and 2.7% in AP on the Vis-Drone2019 validation and test sets, respectively. While maintaining low computational complexity and parameter count, the method demonstrates significant improvements in detection performance. FDM-DETR exhibits robust practicality and reliability in UAV-based small object detection tasks.