Filters email message output that is sent.


(string) (Required) Email message, including processed Smart Tags.
(object) (Required) Instance of the WPForms_WP_Emails class, which handles all notification emails sent by WPForms.



More Information

The wpforms_email_message filter is applied to all emails that are sent from WPForms such as processed Smart Tags and includes the dashes separating the labels of each form field.


When sending plain text emails, it may be necessary to remove these dashes so that you can parse your email information into a Google spreadsheet (for example).

 * Filters dashes from labels on plain text email.
 * @link
 * @param  string $message  Email message including Smart Tags.
 * @param  object $emails   Instance of the WPForms_WP_Emails class
 * @return string

function wpf_dev_email_message( $message, $emails ) {
    // Remove dashes from labels
    $email = str_replace( array( '--- ', ' ---' ), '', $message );

    return $email;


add_filter( 'wpforms_email_message', 'wpf_dev_email_message', 10, 2 );

remove the dashes from your plain text emails with the wpforms_email_message filter

Tutorial Reference: How to Customize the Styles on the Email Template