Beginning C BST implementation
#include &lt;mem.h&gt; should be properly #include &lt;string.h&gt;. The former is non-standard.
I prefer avoiding the duplication inherent in forward-declarations, so would put the definition before first use.
Unless, of course, I'm writing a header-file.
Remember that your friendlyLookup() can fail. And test for that.
It's a bad idea to name the type in a sizeof like in *head = malloc(sizeof(struct bstNode));. Changing it to *head = malloc(sizeof **head); is more resilient to change, obviously correct, and even shorter.
There are a few viable strategies for handling failure:


Ignoring it and hoping the program will crash. Even for toy-programs, that's extremely bad form.
Deteting it and aborting the program with an error-message. Often acceptable when resources are exceeded.
Fixing the failure. Often not possible, or at least not at that place.
Reporting the failure to the caller and letting them deal with it. The preferred method, especially for library-code.


You are instead doing a mixture: Printing an error-message (part of option 2) and then pretending you succeeded. That's a really bad combo.
Learn to love the ternary operator condition ? true-case : false-case. It would often simplify your code.


Applying some of the above:

void die(char* msg) {
    fprintf(stderr, "%s", msg);
    abort();
}

void insert(struct bstNode **head, int val) {
    if(!*head) {
        *head = malloc(sizeof **head);
        if(!*head)
            die("malloc failed!");
        **head = (struct bstNode){.val = val};
        return;
    }
    insert(val &lt; (*head)-&gt;val ? &amp;(*head)-&gt;left : &amp;(*head)-&gt;right, val);
}



if (head-&gt;left != NULL) is exactly the same as if (head-&gt;left).
In friendlyLookup() you are copying one of two string-literals into a (far too big) array, just to copy it again. Why? Use a pointer.

const char* resultString = result &gt; -1 ? " is present in the bst\n" : " is not present in the bst\n";

Also, numberString is far too big, but whatever.
printAndCleanString is a curious name. If such a utility-function makes sense, it should be "free" instead of "clean".
If you want to output a string, don't give it as format-string to printf(), but as an argument. Make it:

printf("%s", string);