When obtaining digital holograms, dark rooms are used to prevent the influence of natural light on the formation of holograms. Further, in recent years, researchers have actively studied machine learning techniques such as deep learning to resolve image-related problems. In this study, we obtained a pair of holograms influenced by natural light and holograms unaffected by natural light, and trained U-Net to perform image transformation to remove the effects of natural light from holograms. Thus, this study aimed to propose a method for eliminating the effects of natural light from holograms by using the U-Net we trained. To verify the effectiveness of the proposed method, we evaluated the image quality of the reconstructed image of holograms before and after image processing by U-Net. The results showed that the peak signal-to-noise ratio (PSNR) increased by 7.38[dB] after processing by U-Net. Additionally, the structural similarity index (SSIM) increased by 0.0453 after processing by U-Net. This study confirmed that in digital holography, holograms can be acquired without the use of a dark room and that the method proposed in this study can eliminate the effects of natural light and produce high-quality reconstructed images.