Smart home integrates disaster protection, medical care, entertainment and energy-saving systems, making the living environment more secure and comfortable. This paper investigates the demand response achieved by the “smart energy management system” in a smart home environment, and aims to obtain the optimal temperature scheduling for air-conditioning according to the day-ahead electricity price and outdoor temperature forecasts. Because the retail electricity price and temperature are predicted 24 h in advance and there exists uncertainty, the predicted retail electricity prices and temperatures are modeled by the fuzzy set. The immune clonal selection programming is employed to determine the day-ahead 24-h temperature schedule for air-conditioning. The electricity expense is hence minimized while comfort is still retained. The simulation result shows the applicability of the proposed method.