This study explores an interesting fluid–structure interaction scenario: the flow past a flexible filament fixed at two ends. The dynamic performance of the filament under various inclination angles (
$\theta$) was numerically investigated using the immersed boundary method. The motion of the filament in the
$\theta$–
$Lr$ space was categorised into three flapping modes and two stationary modes, where
$Lr$ is the ratio of filament length to the distance between its two ends. The flow fields for each mode and their transitions were introduced. A more in-depth analysis was carried out for flapping at a large angle (FLA mode), which is widely present in the
$\theta$–
$Lr$ space. The maximum width
$W$ of the time-averaged shape of the filament has been shown to strongly correlate with the flapping frequency. After non-dimensionalising based on
$W$, the flapping frequency shows little variation across different
$Lr$ and
$\theta$. Moreover, two types of lift variation process were also identified. Finally, the total lift, drag and lift-to-drag ratio of the system were studied. Short filaments, such as those with
$Lr\leqslant 1.5$, were shown to significantly increase lift and the lift-to-drag ratio over a wide range of
$\theta$ compared with a rigid plate. Flow field analysis concluded that the increases in pressure difference on both sides of the filament, along with the upper part of the flexible filament having a normal direction closer to the
$y$ direction, were the primary reasons for the increase in lift and lift-to-drag ratio. This study can provide some guidance for the potential applications of flexible structures.