"low, narrow rock ridge underwater," 1580s, riffe, probably via Dutch riffe, from a Scandinavian source such as Old Norse rif "ridge in the sea; reef in a sail," literally "rib" (see rib (n.)). Also extended to the low islands formed by coral debris or to any extensive elevation of the bottom of the sea.
"horizontal section of sail rolled or folded" to reduce the area exposed to the wind, late 14c., rif (mid-14c. in rif-rope "rope used in tying down a reef"), from a Scandinavian source such as Old Norse rif "reef of a sail," probably a transferred use of rif "ridge under the sea; rib" (see rib (n.) and compare reef (n.1)). German reff, Swedish ref, Norwegian riv, Danish reb likely all are from the Old Norse word.
1660s, "take in, roll up" (a section of a ship's sail or something like it, t reduce the extent of it), from reef (n.2). Later also in a general sense of "gather up stuff" of any kind (1836), hence the criminal slang sense of "to pick" (a pocket). Related: Reefed; reefing.