Decreasing electric grid reliability in the US, along with increasing severe weather events, have greatly increased interest in resilient energy systems. Few studies have included the value of resilience when sizing PV and Battery Energy Storage Systems (BESS), and none have included the cost to island a PV and BESS, grid-connected costs and benefits, and the value of resilience. This work presents a novel method for incorporating the value of resilience provided by a PV and BESS into a techno-economic optimization model. Including the value of resilience in the design of a cost-optimal PV and BESS generally increases the system capacities, and in some cases makes a system economical where it was not before. For example, for a large hotel in Anaheim, CA no system is economical without resilience valued; however, with a $5317/hr value of resilience a 363 kW and 60 kWh solar and BESS provides a net present value of $50,000. Lastly, we discuss the effect of the ”islandable premium”, which must be balanced against the benefits from serving critical loads during outages. Case studies show that the islandable premium can vary widely, which highlights the necessity for case-by-case solutions in a rapidly developing market.