Sending your balloon to space on its own would be fairly pointless, so we need to build at least one enclosure to contain our payload. There are ways to purchase a nearly complete box and ways to build your own custom box for whatever application you might come up with.
One option is a styrofoam/polystyrene shipping cooler. Polystyrene has a special kind of fragility when it is in a thin shape (like for the wall of a coffee cup), but when it is used to form thick walls (like for a cooler) it is surprisingly robust. Probably the most difficult part of working with this type of material will be making access holes without making a huge mess of particles that will use their static charge to cling to everything you know and love (think sand or glitter).
Depending on your approach, you will likely need to make holes for the load line to run through the box, as well as holes in the side for your camera and other sensors to have access to the outside world for direct measurements.
You can avoid some additional holes for attachments by making a sort of sleeve or envelope for your payload box from ripstop fabric[BC1] , and then making the attachment points on the outside of this sleeve with something like nylon loops and/or key rings. This sleeve can also be a great idea for giving your box a bright color and protecting the foam from direct contact with anything sharp that might puncture the box or impair the strength of the box. Overall, the ripstop sleeve eliminates a lot of potential complications from interactions with the environment and integrating the enclosure with the flight train.
One complication that it does bring up is that if you need direct access to the outside air for pictures or other measurements, then you will need to consider how to include windows with the sleeve and line them up with existing or planned access areas. You will also need to securely close the sleeve so that one of your failure modes does not result in your payload sliding right out and plummeting (dangerously and catastrophically) to Earth.
If polystyrene sounds like a good option for you but the dimensions of pre-made coolers don’t work for you, get a sheet of polystyrene. Cut it to your dimensions (use very sharp tools or a wire cutter to reduce the mess), and use epoxy to assemble your enclosure.
Polystyrene can be tricky to attach the electronics and sensors to directly, but this can be avoided by mounting your internal components to a panel (plastic, balsa wood, etc.), and then attaching this larger and more uniform object to an inside surface of the enclosure. You could also attach objects using hook and loop fasteners (e.g. VELCRO®), but the porosity and low cohesion of polystyrene can dramatically reduce the attachment (adhesion) strength using this method.
Some projects use pre-made enclosures, like rigid plastic cases and foam lunch boxes from online or the nearest big-box department store.
Other types of building foam have been used for hobbyist R/C glider airplane wings, so this would likely work well for payload enclosures too. There is at least one rigid blue foam that is used for this purpose because it can be easily and accurately cut with a hot wire cutter.
Foamcore (Foam Board)
The materials and method that I feel most comfortable with is foamcore (a.k.a. foam board). This is often used for various light- to medium-duty crafting and building projects and some poster boards. You can buy sheets in various sizes and it is a relatively affordable material.
Use a meter stick to make long, straight lines in the dimensions that you will need to build your box. A good size to start with for a payload that will have an Arduino, a few sensors, and a simple heater would be a 6” cube. Use a sharp hobby knife (like X-ACTO®) to cut the panels that you need by using 2-5 easy passes of the knife through the foamcore placed on a surface that is safe to cut on (utility table, cardboard, sheet of plywood, etc.). Once the panels are cut, add a 45° chamfer along every edge so that they will all match up when assembled into a cube. Failing to add this chamfers for direct foam-foam bonding with drastically reduce the strength along the seams.
To start assembling your enclosure, it is extremely helpful to find a “jig” to help align all of the panels orthogonally to each other (i.e. mutually perpendicular, like the three sides of a box that intersect at one corner, or XYZ/Cartesian coordinate if you want to get technical). Don’t panic! If you have a spare cardboard box and an extra set of hands to help you for a few minutes then you have everything you need, except tape and glue.
Have one person hold two panels together along an edge of the box while the second person tapes them together with 2-3 pieces of masking tape. Next, move to a corner of the box and use it to help align and tape the third panel in place to JUST ONE of the other panels on one edge. Remove this taped contraption and lay it out flat on the table (with chamfers up), which should appear as three boxes arranged to look like and “L.”
Along the two edges where there is already tape, apply a fairly generous bead of RTV sealant (standard “black” RTV is recommended) along the length of the seams that will still be joined. Also add a bead to one side of the seam that will be formed when the three pieces are folded back together to make half of a cube. Use extra RTV if you see large gaps in between the sides so the gaps will be filled and use less RTV if the pieces look like they will come together very nicely. Fold the three pieces together now and tape the third seem that is formed with when these pieces are put together. This is a good time to add two more panels and glue them in place because you have a rigid structure with good dimensions to guide the other two pieces and the RTV takes about a day to dry. You can cut your construction time in half by gluing it all together now. If you find that the panel lengths don’t match up as you planned, try to make all of the existing eight seems as tight as possible and then trim the top/open edges once the RTV has set and you can handle the box as a single piece.
Don’t skip adding chamfers to the panels because adjoining them along the paper edges will greatly reduce the strength because the paper can peel off, while joining them foam-to-foam keeps the joint impressively strong. Hot glue is not a good choice for this application because of the glue’s short set time and the high temperature will degrade the foam, causing bubbles (weakening the bond) and smoke (which cannot be good to breathe in).
Attach metal washers using RTV or epoxy to the center of the top outside and bottom outside of the enclosure (a good shortcut for finding the center of a square or rectangle is to draw a straight line between each pair of opposing corners and then the lines will cross at exactly the center) that are big enough to let the payload string pass through under normal conditions, but small enough so that a knot will not pass through. Fender washers are a good choice because they have significantly more surface area for the same size whole when compared to a regular metal washer, which will be nicer to your payload materials when undergoing stresses during flight.
Attach the top/lid panel with a hinge of aluminum tape and then on the day of the flight (or as needed) tape this last panel closed with more aluminum tape.
Guidance for All Custom Enclosures
Cut Smoothness and Dimensions
It is important to make straight cuts, but it is even more important to monitor the overall straightness and dimensions of your cuts. That is, making perfectly smooth cuts is good, but most roughness in the cut can be compensated for with the epoxy, RTV, or other gap-filling adhesive used. The real issue is when the overall length, squareness, or straightness is off because this will cause misalignments that will make it very difficult to join the panels of your enclosure and it is also hard to make corrections by sight, so just make the measurements right the first time and stick to them.
Warning About Radar Reflectivity
The aluminum tape used to hold the enclosure together will reflect radar waves, but this does not mean that the external tape can automatically be used as a radar reflector for flight (this goes against some advice in at least one popular HAB resource). This is because, on each side, as it is built in these (and all) instructions, the radar waves will only reflect in one direction, in the same way that visible light reflects off a mirror. This will cause the radar reflection to only be visible in one very specific direction, which is almost guaranteed to not be the right direction. Your enclosure can actually be modified to be an appropriate radar reflector, but it won’t be by default when you put aluminum tape on it. More on this in the Radar Reflector chapter.
Don’t Make it Literally Airtight
One word of caution for the extremely ambitious: If you make your enclosure airtight, it will explode (well, it will at least pop/break). For the same reason that the balloon lifting your payload will eventually pop, your enclosure will too if you manage to make it airtight. You could, I suppose, design it to also be strong enough to withstand the pressure difference, but that would be as much overkill as using scuba gear to take a bath.
Balance Near the Center of Mass
Take care to balance components so that the center of mass is as much as possible along the vertical, center axis of the box to prevent extra swinging of the payload during the flight.
Switch and Indicator Placement
During construction of your electronics system you will likely find that you want to put switches on the outside of your enclosure so that you can control power systems from the outside even when the enclosure has been sealed for flight. It will be a little easier to make these holes before the enclosure panels are put together, but it then opens up the possibility of assembling the panels incorrectly while also forcing you to plan much of your electronic system much earlier than required. At the same time, I have seen that it is still quite straightforward to add button, indicator, or sensor access once the enclosure’s overall structure has already been assembled.
If you put switches and sensors on the outside of the enclosure then you will also probably want to protect them with some sort of shroud, which can also easily be made from foamcore. You might add a flap, or some other kind of cover, that has been built up around the buttons to make sure they are not hit accidentally by a person, in-flight jostling (especially if there is more than one box), or being depressed by debris on landing.
Isolating Structure and Electronics
Consider placing a tube (such as thin-walled PVC pipe) inside of the enclosure running between the top and bottom holes used for the payload line so that the wires inside do not get tangled with —or disturbed by— the load line.
You will want to put some helpful information on the outside of your enclosure in case someone else finds your payload before you do. At a minimum, some contact information is essential. In addition, you might also want to add a little information about what is in the box (“Hobbyist/Citizen Science Experiment” for example) and what people should do if they find it. I also like to let innocent bystanders know that it is a “NON-Hazardous” payload or that it is “NOT Dangerous.”
You can help unsuspecting passersby be part of your recovery team by making your box brightly colored. Even if you are the one to find your spacecraft, it wouldn’t hurt to have it colored brightly in case it lands in a dense field or among trees.
 Conversation with Luke Geissbuhler