Given the increasing use of (de)centralized renewable energy, there is a growing need for flexibility to handle the uncertainty of the renewable energy supply.Flexibility is a strategy which describes the ability of a system to handle and respond to changing requirements. In view of the grid environment, powersystem flexibility can be defined as systems with the ability to continuality balance the electricity supply and demand in cost effective way, whilemaintaining the required services towards grid connected loads. Building energy flexibility forms part of the Demand Side Flexibility (DSF) category.Buildings offer DSF by decreasing energy demand or supply energy during peak periods. Integration of Battery Energy Storage Systems (BESS) increasesthe DSF opportunities and in combination with active controllable loads can handle on-side disturbances, beforehand the electrical flow will influencepower grid operations. In this study an office building integrated BESS is designed, developed, built and commissioned in order to test Smart Gridfacilitating Demand Side Management (DSM) strategies. Studies emphasize two important issues in successful integration of BESS: energy efficiencyand battery degradation. A good understanding of the BESS characteristics is therefore crucial and assessment of the BESS performance under variablecharge rate (current) and Depth of Discharge (DoD) of the batteries is needed. The second part of this study describes the BESS as an application forcontrol strategies towards the Smart Grid. A BESS software agent is designed that respond to the day-ahead electricity pricing and building energydemand and schedules the battery discharge profile. To conclude, the agent is able to: communicate between different parties with the use of JSON, it canuse forecasted building energy demand data and schedules the load output in an iterative process.