A D-shaped photonic crystal fiber (PCF) polarization filter and sensor with a standard hexagonal arrangement of pores is designed. The effects of geometric parameters, metal film thickness, liquid refractive index, and optical material refractive index on polarization filtering and sensing characteristics are analyzed by the finite element method (FEM). The proposed PCF shows single-polarization filtering in communication window and has ultra-high corresponding bandwidth. At the 1.55 µm communication window band, the confinement loss of the y-polarized core mode is 819.27 dB/cm, while the x-polarized core mode is only 3.45 dB/cm. The crosstalk (CT) reached a maximum of 708.6 dB in the communication bands, and the corresponding bandwidth reaches 1000 µm when the fiber length is 1 mm. Meanwhile, the D-type PCF is widely used in sensing because it avoids filling the gold film and analyte in the internal pores. The change in the thickness of the mental coating from 39 nm to 22 nm provides the proposed PCF with sensing properties. By reducing the refractive index of fiber material, the maximum sensitivity is 10,741 nm/RIU. When the refractive index measurement range of the analyte is specified from 1.33 to 1.36, the average sensitivity reaches 7313 nm/RIU. Good performance enables the proposed compatible filtering and sensing PCF may be used in a wide range of scenarios.