Excimer laser at 248 nm has been used to micromachine holes and channels on stainless steel and polymethyl methacrylate using mask projection methods. The machining is numerically simulated considering the laser beam as a heat source only, thermal diffusion, and melt vaporization. The depth and width of the machined features at different pulse energies and number of pulses are measured by optical profilometry. Both the depth and the aspect ratio (depth-to-width) are found to increase with increasing number of pulses and pulse energies. The depth predicted by the simulations based on the thermal ablation model is closer to the experimental observations for steel as compared with that for the polymer. This allows for the quantification of the contribution of thermal ablation processes in the excimer laser machining of metals and polymers. High-energy pulses are found to have higher ablation efficiency in case of metal and lower ablation efficiency in case of polymer.