In this paper the problem of the spectrum optimization in Ultra Wideband systems is investigated. A UWB system based method by which the transmit signal fits optimal to the given mask, is presented. According to this method, a particular filter structure is designed, which allows for compensating the non-ideal behavior of the pulse generator and the antenna of the UWB transmitter. Using the proposed method, a filter has been designed and fabricated for a particular antenna and pulse generator. For verification, measurement results are presented.