Despite the name, fortune cookies are an American invention — likely originating in early 20th-century Japanese-American bakeries in California, then adopted by Chinese restaurants. They're virtually unknown in mainland China except as an imported curiosity.
签 (qiān) refers to the fortune slips drawn at temples;
语 = words;
饼 = cookie/cake.