This paper proposes a novel design of a software-defined matched filter (MF) for digital receivers of synthetic aperture radar (SAR). The block diagram of the proposed receiver is described in detail. The purpose of this filter is to produce a SAR pulse with higher compression ratio (CR) and lower side lobe level (SLL) than that produced by the conventional MF. The proposed design is based on the idea of time windowing of the SAR pulse to construct the transfer function of the receiver filter. The shape of the proposed time-domain window is optimized to achieve the filter design goals including the minimization of the SLL and the realization of the target value of the CR. The transmitted SAR pulse is, first, subjected to linear frequency modulation and then subjected to the optimized window. The width (time duration) of the proposed window is divided into equal time intervals. The proposed time-domain window is constructed as a sequential continuous piecewise linear segments. The instantaneous value of the time-domain window at the start of each time interval is optimized so as to achieve the optimization goals. The width of the time-domain window is shown to be proportional to the width of the compressed pulse after optimization. The number of the time intervals into which the time duration of the window is divided is shown to have a significant effect on the optimization results. The particle swarm optimization (PSO) technique is then applied to get the window shape that minimizes the SLL for a specific predetermined value of the pulse CR. It is shown that the iterations of the PSO are fastly convergent and that the applied algorithm is computationally efficient. Also, it is shown that the desired value of the pulse CR is achieved with accuracy of 100%. Moreover, the achieved SLLs are about − 65,mathrm{dB}, - 90,mathrm{dB}, - 114,mathrm{dB}, and - 133,mathrm{dB} for pulse CR of 5, 3, 2, and 1.5, respectively. Finally, for practical implementation of the introduced SAR pulse processing technique, the proposed optimized window is placed as a building block in a software-defined receiver of the SAR system.