From BeepBox Wiki

BeepBox wasn't recognized as being able to use audio files for sound, and it stayed this way until PaandorasBox. It was acknowledged that the chip wave instrument type, with how it was made, could support sound files by loading in the values of each wave point in the file. UltraBox released far later and introduced custom sampling, allowing importing sound files into the program via a link to the file, commonly set up with filegarden/other file hosting sites.

Details (PaandorasBox Samples)

The samples are contained within the chip wave's chip selection, found at the very bottom of the list. They will play a sound file using the method explained earlier. However, there isn't an easy or cheap way to individually control the sample's speed and pitch other than to change the pitch the sample is playing in, which changes both, and at this point in time, samples weren't importable and the way they looped was uncontrollable, and so were the caveats people used samples with.

Thurmbox came out later, adding a large gallery of sampled noises that could be added in from typing in a string of characters assigned to each sound, and other mods (BlockBox, NintariBox, and MarioPaintBox to name a few) added their own built-in sounds to pick from.

Details (UltraBox and forks)

Upon request, developers of UltraBox developed a way to add in sound files freely. This is accessible within the custom sample prompt found in the edit menu of the program or by pressing Shift+Q on keyboard.

The prompt contains some text explaining how sampling works and buttons for adding samples in. By pressing on these buttons, a white textbox area appears where you can put in the links to sound files hosted in other websites to import them into the program. You can type in specific names (legacysamples, nintariboxSamples, and marioPaintboxSamples) to insert built-in sample packs into the song based off of the PaandorasBox mods that added them. There exists syntax while typing/pasting in file names that can be used to quickly apply settings as well. You can also adjust the options of samples from the sample list in the prompt, allowing the user to adjust loop sizes/modes, playback in reverse, etc. There is a 'practical limit' of 64 samples (this limit can be raised, but is kept down for performance), when samples are loaded in, they can be found inside of their own preset category of the preset select or in the chip wave selection (sample packs will not appear in the preset category), and samples are stored at the end of the song's URL as their file names.

Outside of the prompt, UltraBox also added a few more things in relation to samples. If the "show sample loading status" preference is enabled, in-between the song and instrument settings will be a sample bar displaying the number of samples that have loaded in and the ones that have encountered an error, and is also used to know when all samples have loaded. Clicking on this bar shows more details on each sample and its status. A change was made to the chip wave instrument type for quickly accessing chip wave loops. A checkbox is shown underneath the chip wave select box, and when ticked, more options appear for editing the loop points of the wave. This also applies for any chip wave in general, and these settings also come with their own prompt accessed by pressing the '+' button found to the side of the "loop start" input box. The prompt contains roughly the same settings as what is seen in the editor, but with a much more easy-to-configure space for changing loop points.