The invention provides an optical fiber sensor for monitoring the flow velocity of fluid in a pipeline, and belongs to the technical field of measurement. The optical fiber sensor for monitoring the flow velocity of the fluid in the pipeline comprises an optical fiber, an optical fiber protection armor, an optical fiber fixing hoop, a metal cushion block, a ceramic rod piece, a ceramic sheet, a spring top seat, a spring, a spring base, a reflecting mirror surface, a hollow cylinder, a ceramic shell, a ceramic ring and a bearing. The device realizes real-time monitoring of the flow velocity of the fluid in the pipeline by observing the change of the spectrum in the spectrograph and applying the Fabry-Perot optical fiber interference principle, the principle that the force generated when the fluid flows through the sensor is equivalent to the internal force generated by the spring and the relationship between the fluid resistance and the relative velocity, thereby ensuring the safety and stability of pipeline transportation. The device is low in labor cost, easy to operate and wide in coverage range, and has wide application prospects and popularization markets.