The purpose of this study has been to demonstrate the possibilities of uniform heating of a cavity, with great accuracy, by means of an integrated resistor built with the same dimensions as the cavity, i.e., with a high level of integration. For application purposes, a compact resistor allows increasing the number of cavities in which temperature can be independently controlled on the same substrate, which can prove critical for high-throughput screening applications. Potential applications lie in the field of biology or chemistry. In order to achieve the desired result, an optimization procedure was performed on the shape of the resistor. The heater size reduction enables a high level of integration with a reduced heating source surface area. Resistor shape has been optimized to reduce the influence of boundary effects, using improvements introduced in genetic algorithms. An experimental validation of the temperature profile inside the cavity has been carried out using a dye whose fluorescence depends on temperature, i.e., Rhodamine B, it will be shown herein that the optimized resistor allows for temperature cycling, e.g., for PCR applications.