This study explores microgrid scheduling for drilling operations using hybrid energy, with a focus on managing an energy storage system (ESS) and utilizing a diesel generator for backup. The optimization process encompasses backup from the diesel generator, renewable energy integration, energy storage utilization, and network load management involving various equipment. MATLAB software was employed for simulation and analysis. The research underscores the significance of energy storage in managing peak workloads, devising backup generator schedules, and regulating loads to explore potential economic advantages like fuel savings through hybrid energy and battery storage supported by the diesel generator. It assesses production power, cost savings, pollution mitigation, and enhancement of power quality. The test duration spans approximately one working month of the drilling machine at 24-hour intervals and extends to cover the entire drilling operation period. The proposed ESS system for a land rig is projected to slash CO2 emissions by roughly 5000 tons throughout its operational lifespan. Furthermore, it indicates a potential 22% decrease in fuel energy consumption compared to current plant management practices.