Outlook doesn't have a built in method you can use to automatically include yourself (or other email address) in the BCC field when you send a new message. You can use Rules Wizard to CC and address but not to send a BCC.
To BCC the message, you need to either use VBA or a utility listed below.
Always BCC Code Sample
Basic VBA instructions are below, instructions with screenshots are at How to use Outlook's VBA Editor .
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address
' or resolvable to a name in the address book
strBcc = "address@domain.com"
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
BCC Some but not All Messages
If you need to BCC, some but not all, messages, you'll need to use an IF statement to filter the messages. While you can filter on To, subject, or category fields, if you need to use series of If statements, filtering by category may be the easiest.
This code block BCCs one address if the category is Personal, another if the category is Important and exits if there is no category. It could easily be switched around to exit if there is a category and BCC everything else.
To add a category to email, click on the Expander
in the Tags group and choose the Category from the options dialog. You could also use a macro to add a specific category to the ribbon for easy access. Get the code from Adding Categories when Composing Email.
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
If Item.Categories = "Personal" Then
strBcc = "address@domain.com"
ElseIf Item.Categories = "Important" Then
strBcc = "new@address.com"
Else
Exit Sub
End If
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
BCC Messages sent From a Specific Account
If you have multiple accounts in your profile and only want to BCC messages sent through a specific account, use an IF statement to check the SendUsingAccount value. Be sure to use the account name as it appears in the From field or Account Settings dialog.
To BCC from all but one account, replace the = sign in the If statement with <>.
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
strBcc = "alias@domain.com"
' Use the account name as it appears in Account Settings
If Item.SendUsingAccount = "account@domain.com" Then
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
End If
Set objRecip = Nothing
End Sub
How to use VBA
You will need macro security set to low during testing. To check your macro security in Outlook 2010 and up, go to File, Options, Trust Center and open Trust Center Settings, Macro Settings. In Outlook 2007 and older, it's at Tools, Macro Security.
After you test the macro and see that it works, you can either leave macro security set to low or sign the macro.
- Open the VBA Editor using Alt+F11.
- Expand Project1 and double click on ThisOutlookSession.
- Copy then paste the macro into ThisOutlookSession. (Click within the code, Select All using Ctrl+A, Ctrl+C to copy, Ctrl+V to paste.)
Don't forget to replace address@domain.com with the correct address.
Tools
Sperry Software's Always BCC add-in for Outlook is being released for Outlook 2010. The add-in automatically adds a CC/BCC email address to all outgoing emails - making it perfect for compliance reasons. It can also include a cc or a bcc based on conditions you set up, for instance if you are sending from a particular account. The add-in now works with both 32-bit and 64-bit Outlook. | |
This add-in automatically creates a BCC (blind carbon copy) or CC (carbon copy) for all or some of your messages based on simple rules that you set. It can send a BCC/CC for all outgoing email messages to specified addresses or with certain words in the subject or attachment name, e-mails sent from all or some of your accounts. You can create very flexible rules for every occasion, introduce exceptions and use several keywords in one field. The plug-in works in Microsoft Outlook 2007 and newer. | |
Sperry Software Compliance Copies add-in for Microsoft Outlook will automatically add multiple BCC or CC recipients based on multiple different rules for different people. Unlike the Always BCC add-in, this new add-in also supports exceptions to the CC/BCCs conditions. This tool works with Outlook 2007/2010/2013. | |
Create rules for filling TO, CC, BCC and SUBJECT fields of new message based on the folder where the original message is stored. Add-in allows to use different settings for different folders. The fields you don't want to change will remain the same. It only allows automatic address management, while message body remains intact. Works with Microsoft Outlook 2000 and up, fully compatible with Microsoft Exchange Server public and shared folders. Part of the MAPILab Toolbox. | |
Outlook plays a vital role in terms of office productivity in communication. However, there are some features missing, such as auto-BCC, Gmail Push Notification, and standardized import/export on contacts, calendars and tasks. Power Toys for Outlook is a collection of Outlook add-ins that provides these useful features. Auto BCC for sends blind carbon copy to recipients. Export Outlook Contacts to a single vCard (.vcf) and Excel. Export Outlook Appointments and Tasks to ICAL (.ics). GGNotify enables push notification from Google upon new e-mail arrival. | |
If you want to monitor every email that leaves your company, Silent BCC for Outlook is the right tool. Once installed, the plug-in will deliver you BCC copies of all messages sent from all accounts of a PC. Users won't know that a BCC copy was sent from their machines, since the add-in is invisible in Outlook and BCC addresses are removed from Sent Items. Users can't turn the plug-in off or alter your settings. You can tweak the add-in to be copied on each outgoing email or allow exceptions. | |
SilentMail for Outlook monitors outgoing emails and sends a blind carbon copy (BCC) of every email to a specified address. SilentMail for Outlook does this by copying the message from the Outbox mail folder, making the monitoring process invisible for the user. Supports all versions of Outlook. Does not require Exchange server. | |
TuneReplyAll shows a warning message when a user is going to reply to everyone. The user has to confirm his choice to reply to all. This will help to prevent sending out confidential information. If Outlook includes the user's own address in Reply all, TuneReplyAll will remove it from the message. |
Automatically BCC using Smartphones
While not "an Outlook problem", automatically BCCing when sending mail from a smart phone is a popular feature. Because the mail goes directly to the SMTP server, Outlook's ability (or lack of it) is not a factor; it's all about what the smart phone software supports.
IPhone and iPad users can set the device to always BCC your address in Options > Mail, Calendar, and Contacts.
Automatically BCC using Exchange Transport rules
Administrators of Exchange Server can configure a transport rule, or in Office 365, a Mail flow rule, to BCC messages to another address, bypassing the need for VBA or other solutions (and without the user's knowledge).
Transport and Mail flow rules can be created and configured using a cmdlet or from the Exchange System Manager console.
More Information
Exchange 2007 Message Transport Rules
To automatically Bcc all outgoing messages - OutlookCode.com
How to use Outlook's VBA Editor
Reply to All Includes My Address
Warn before sending messages to the wrong email address
Victor says
Use this freeware: https://ivasoft.com/autobccflow.shtml
John says
Diane, very interesting topic, I have never thought about using VBA to Bcc myself, what about using the new quick steps funcitonality? would you recommend? Cheers
Diane Poremsky says
Quick steps would work, but you need click the Quick step button to reply. The macro automatically adds the BCC when you send.
Quick Steps is good for occasional use, the macro to BCC every message.
Mohammed says
Does anyone know how to implement this Always BCC Code Sample in MAC OS outlook ?
Diane Poremsky says
Outlook mac doesn't support VBA - but if you are BCCing all messages, Outlook has the option in Preferences- it's under Composing.
Mike Czabala says
Diane,
I CAN'T THANK YOU ENOUGH!!!
Recently I had to move to Outlook 365 due to a fatal sync error with Outlook 2007. Previously, I was using an add-in that auto BCC'd from my two work email addresses (but not from my personal email) in Outlook so that my web-based CRM could capture and store emails based on the "To" recipient field in the original.
When I made the move to Outlook 365 my add-in no longer worked (didn't support Win 7 Pro 64 bit and Office 365 64 bit).
I searched for about 5 hours today for a solution and then I landed on your website. I used your VBA code but modified it to add a 2nd If/Then loop for my 2nd work email and it works perfectly! (I haven't programmed since college, and that was a long, long time ago, but I was able to follow the syntax and successfully make this change.)
Thank you! Thank you! Thank you!
Mike
Martin says
Hello, is there any way that I could make this merely fill the field, not do it after clicking send?
Diane Poremsky says
You can have it filled in when you click New message or reply.
https://www.slipstick.com/developer/code-samples/default-subject-messages/
There is an example there to CC, that can be changed to BCC.
Martin says
Right, I've tried that one, with no success, and I'm assuming that is because I'm using office 365 outlook. Is there anything for newer versions?
Saleem Ahmed says
In Case u have multiple email accounts in outlook and desire to Auto BCC each email account separately....try following code
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
Dim strBcc1 As String
On Error Resume Next
strBcc = "cfopidc@gmail.com"
strBcc1 = "cfonip@gmail.com"
' Use the account name as it appears in Account Settings
If Item.SendUsingAccount = "CFO@PIDC.COM.PK" Then
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
If Item.SendUsingAccount = "saleem_ahmed@nip.com.pk" Then
Set objRecip = Item.Recipients.Add(strBcc1)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
End If
End If
Set objRecip = Nothing
End Sub
Dave says
This does forward my emails, but as a cc:, not a bcc:.
Diane Poremsky says
If you are using the BCC field in the code and i's not working, is the address in the BCC field when you send it? If so, your mail server i changing it.
Dave says
no it is in the cc: field. it must get added after I push send.
Diane Poremsky says
Do you have a rule set to CC outgoing messages? The CC would be added as it was sent in that case.
Kwame Poku says
How can you edit the code to Bcc to multiple email addresses?
tried assigning multiple addresses to the 'strBcc' but gives me error msg when i send mails
Diane Poremsky says
You can't (usually) put everything in one string. If you do, don't use the resolve lines - let outlook resolve it on send.
To enter multiples you need to repeat these lines:
strBcc = "address@domain.com"Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
[snip]
end if
You can shorten it using an array or select case to loop.
Mehran says
I have repeated these lines to add a second BCC recipient, however it only goes to the first BCC not the second one. Could you please rewrite the whole code for 2 BCC's. Thanks.
HmmmUK says
Thanks for your 'auto BCC' docs they've proved very useful over the years.
I'm currently running Outlook 2010 and my W10 PC has just upgraded to version 1703 the Creators Update.
I've noticed that my 'auto BCC' macro has stopped working!?
Any tips to fix this? - I've resaved the VBA project which has worked in the past, but no joy so far.
Thanks.
Diane Poremsky says
it should work... what is your macro security setting? If the macros are signed with selfcert, you may need to make a new signature but you should definitely re-sign them.
HmmmUK says
Hi, Yes I know it 'should work' ;)
As I mentioned it was the last lot of updates that broke things for me - W10 Creators Update and/or Office updates.
I seem to be up and running again after reading of peoples problems elsewhere.
My macro security settings are unchanged:
"Notification for digitally signed macros, all other macros disabled."
But I did also select: "Apple macro security settings to installed add-ins."
as I read that that has helped some people.
Then I found that running Outlook as an Administrator causes Outlook to ask for permission for the macros.
Accepting everything from 'Microsoft as a publisher' when prompted and then closing and restarting Outlook normally seems to have done the trick!
Hopefully this will help others seeing my problem :)
Amit says
Hi,
i want auto bcc in outlook 2016.
i tried your code but for me its not working.
i copy your code, paste also, do certification also, run also.
but while i send mail to any body i didn't get bcc mail.
Thanks
Amit
Norberto Bochner says
This is what I do with Outlook 2010:
No need to write code (therefore no need to reduce security), there is a simpler method:
In the Home screen, select “Create New” in “Quick Steps”.
Give it a name, for example: NewMail.
In the Select Action window select “New Message”
Click in “Show Options”
Click “Add Bcc” and insert the required email address to Bcc in the Bcc window
Click Finish.
Now, every time you want to write a new email, just click on the quick step that you created, and the Bcc will be added automatically, however, no Bcc will be added for forwarding or replay.
For that you have to repeat the above steps and create quick steps for forward, replay and replay for all.
Thiago says
Works seamlessly, thank you
Lindsay says
Hi - I've used the Always BCC VBA script for the past month or so (worked perfectly). My company just upgraded to Outlook 2016 and now it stopped working. I checked in the ThisOutlookSession and the code is still there, but doesn't run. Any idea?
Diane Poremsky says
did you check the macro security settings too?
Lindsay says
THANK YOU! I didn't know that would reset to the default. I just had to change it to "Enable all Macros" and reboot Outlook. I appreciate your quick response!
Frank Collins says
Hi Diane
I use Outlook 2013. My wife and I have separate IMAP/SMTP accounts with separate Profiles but use the same mail provider, iinet.
My macro to automatically Bcc myself for every email I send works 99% of the time, but unaccountably fails. The 'failed' email is sent, and reaches the recipient, but is not Bcc'd into my Inbox. My macro is as follows:
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address
' or resolvable to a name in the address book
strBcc = Item.SendUsingAccount
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Is there anything wrong with it? Or is there something else I can do to resolve?
Cheers
Frank
Diane Poremsky says
The code looks good. Is the bcc address visible in the sent folder? Could a spam filter be catching it? Are you sending a large number at once, such as in a mail merge or if you don't use send immediately?
Faraz says
Hi Diane,
I want to automatically BCC all my emails to my personal email address via VBA code which is working fine. But when I go to sent items BCC field is visible to me, I want to hide it from myself as well so that even it is not visible to me.
Can anyone please help on this with VBA code. Thanks
Currently I am using the following code:
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean) Dim objRecip As Recipient Dim strMsg As String Dim res As Integer Dim strBcc As String On Error Resume Next
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address or resolvable
' to a name in the address book
strBcc = "privateemail@gmail.com"
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want still to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc Recipient")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Diane Poremsky says
You can't hide the BCC field in your Sent folder - it's not something you can control using code either. Sorry.
Will says
Thank you for posting this. I was attempting to utilize your BCC Messages sent From a Specific Account script but in reverse. Meaning only send Bcc replies from emails in specific categories. I tried editing the script but couldn't seem to get it to work.
Joe says
cut-n-pasted the 'Always BCC Code Sample' into ThisOutlookSession. Pressed F5 to Run (test). Prompts for Macro Name??
It is caused by the existence of parameters (if removed, it Runs, but of course, fails).
Saved, restarted Outlook. no bcc on new messages.
while testing, macros are set to Enabled in Trust setting.
no error messages.
Diane Poremsky says
The macros with text between the () run automatically - you can't run them using F5. Add msgbox " I'm sending a message" as the first line after on error resume next and see if it triggers. If so, comment out on error resume next and try again - if the debugger comes up, click Debug so you can see where it failed.
Randy says
Diane, when I used the ; to add a second address to be bcc'ed, it cant resolve the second address, although it does resolve both addresses individually. Its when I add a second one that it wont resolve it. Any ideas?
Diane Poremsky says
Try repeating these lines -
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
instead of strbcc, use the address in quotes.
FAheem says
Hi Diane
my message might seems naïve as I am only a user not knowing anything about development but I used this code few months back & it worked wonderfully well, no trouble at all.
HOWEVER, last week I have to get my HDD re-windows 7 and after putting this code in outlook 2010 .... sadly NOT working.
I simply copied & pasted the rule & tried by putting my email ID "example@gmail.com" NO RESULT, even by putting example@gmail.com NO RESULT (I means this time ID wout comma)
can you put some light on this!
regards,
FAheem Iqbal
Merry Christmas !
&
Happy new year
Diane Poremsky says
Did you check the macro security settings? Look in Outlook's File, Options, Trust Center, macros - set it to low then restart outlook.
Randy says
Diane, that solved the problem! Thanks so much for your help. The world needs more problem solvers like you, willing to take the time to help.
Randy says
Diane, I tried your instructions below for adding two bcc addresses, but it is unable to resolve the bcc address when I separate them with either a semi colon, or a semicolon followed by a space. Any ideas?
Diane Poremsky says
This worked without error - i need that resolve in each, otherwise it errors.
Set objRecip = Item.Recipients.Add("alias@domain.com")
objRecip.Type = olBCC
objRecip.Resolve
Set objRecip = Item.Recipients.Add("alias2@slipstick.com")
objRecip.Type = olBCC
objRecip.Resolve
Marid says
Nice! Diane You solved it! that worked perfectly with a shorter code
Thank you
Vahid Jafarov says
Thank you for helping.It realy works.
MJ says
This worked perfect!
Erik says
Hi Diane,
Thanks very much for providing this script! I had been using it successfully until my hard drive at work was re-imaged and now I can't get it to work. I've put my own email address (xxx@yahoo.com) in, self certified the code, set security, and tried to run the macro. If I try to run the macro the Macros dialog pops up but fails to show any macros in Project 1 (VBAProject.OTM). I'm a little baffled at this point.
Thanks!
Erik
Diane Poremsky says
These macros autorun - they won't be listed in the Macro picker, only in the VBA editor. I highly recommend not signing a macro until you are 100% sure it's working as you can't edit it once signed unless you remove the signature and re-sign it. Set security to low, add the macro to thisoutlooksession and restart outlook. Test it. if it works, then sign it and choose warn for signed macros - then restart outlook and accept the digital signature when the dialog comes up asking to trust it.
Tony says
Hi Diane,
The auto BCC works perfect for me on Office 2013, is it possible to hide the BCC address such that it doesn't show up anywhere including the draft and sent items folder?
Thanks
Tony
Diane Poremsky says
You can remove it from the list view but the reading pane and open messages will show it. You can minimize the header so it's not so huge (use the ^ caret on the right of the header section).
Lisa says
My case is I have 2 mailboxes under exchange service, I just want the bcc works when I use one of the mailbox to send out email.
Diane Poremsky says
Do you get any error messages? The code sample you posted is working here - only messages sent from account@name.com are bcc'd. messages sent from other accounts in my profile aren't bcc'd.
Diane Poremsky says
BTW, you need to use the display name as it appears in the account list in Account Settings.
Lisa says
I tried to use the "If Item.SendUsingAccount = "account@name.com" Then" to do the conditional bcc but it is failed, can you please help?
My code below:
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
strBcc = "account@name.com"
If Item.SendUsingAccount = "account@name.com" Then
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want still to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc Recipient")
If res = vbNo Then
Cancel = True
End If
End If
End If
Set objRecip = Nothing
End Sub
Dan says
Hi Diane,
Is it possible to only BCC when sending emails from certain email accounts?
Diane Poremsky says
Yes, you can use an if statement to bcc only when sending from specific accounts. I think i have the code around here to do that.
Diane Poremsky says
Add this before the strBcc line:
If Item.SendUsingAccount = "account@name.com" Then
use the account name as it shows in the From picker and Account setting dialog - usually the email address but not always.
At the end of the last end if, add another end if.
Frank Collins says
Hi Diane
I run IMAP email accounts under Outlook 2007, and had Dan's problem also. I modified the VBA code as you suggested, the relevant parts are as follows:
If Item.SendUsingAccount = "frank@domain.net" Then
strBcc = "frank@domain.net"
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
End If
Set objRecip = Nothing
End Sub
Is the code correct? It didn't work. What I want is for a copy of emails I send to reside on my mail server so that I can access them via my smartphone, or from any mobile device.
Before I modified the VBA code the bcc feature was working well, except that a copy of emails sent from my wife's account (sue@domain.net) ended up displayed in my Inbox - not what we want.
Incidentally, I had to create my own digital certificate for self signing to even get the original macro to work.
Can you help?
Regards
Frank Collins
Diane Poremsky says
This line tells it to only apply to this specific account:
If Item.SendUsingAccount = "frank@domain.net" Then
It uses the display name of the account as it appears in Account Settings. Newer versions of Outlook use the email address but I don't recall off hand when that changed.
Paul de Fombelle says
Thank you Diane,
Type is indeed olBCC, but it's showing cc in Sent folder. So it's probably something in the server, I'll ask the admin.
If he can't change anything, would it be possible to use a different trick: prefill the cci field in the message before sending, instead of inserting a bcc when it's sent?
Diane Poremsky says
Do you want to CC every message? If so, yes you can prefill it as the message is opened.
Paul de Fombelle says
Hello Diane,
Thanks for your code, and for continuing answering the questions.
I tried a lot of codes before yours, and I always have the same problem: it looks like it's working perfectly, but actually the email address is ccd instead of bccd.
Any idea why this happens?
We are using Outlook 2010 with Exchange.
Thanks again!
Diane Poremsky says
This is what sets it as BCC: objRecip.Type = olBCC
If that line is processing it, the message should be Bcc'd. Is it showing as BCC in the Sent folder? If so, it's possible something on the server is changing it - email scanner or transport policy are the most likely suspects.
Max says
Hi, thanks for this. In Outlook 2010 I got it working but trying now in Outlook 2013 it doesn't work. Can you please copy the final clean code again so I can copy-paste just as is into the VBA? Do I need to remove the green text (#USER OPTIONS etc) or not; remove line breaks etc or remove nothing? I don't get any error message; it just doesn't send the blind copy to the specified address. Many thanks,
Max.
Diane Poremsky says
Is macro security set to the lowest settings? That is the usual cause of macros not working when switching versions.
Max says
Hi Diane,
Thanks for your reply. It is now working fine. What I did wrong, I assume, is that I pasted the code in a new module instead of directly into the ThisOutlookSession window, because I followed the instructions for "sign the macro" (link in the "How to use VBA") instead of the instructions in this article above.
Thanks again; also for your very informative articles in general!
Jacob says
Hi,
Thank you for this! I'm just having an issue when trying to exclude an email group in outlook for the national team so that only external emails are bcc'd, my code looks as follows.
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
If InStr(LCase(Item.Recipient), "National Team") Then
Exit Sub
Else
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address or resolvable
' to a name in the address book
strBcc = "bcc@email.com"
blahblahblkahbalh
End If
End If
End If
When I enter the extra bit to exclude addresses in the National Team group it no longer BCC's at all.
Am I doing something wrong here?
Thanks in advance
Diane Poremsky says
You are using Exchange server? Internal addresses don't have an @ sign and have /ou in the address, which you could look for to identify internal email.
The lcase converts the recipient name to lower case - but national team is in proper case, so it's always going to fail:
If InStr(LCase(Item.Recipient), "National Team") Then
This should work - it gets all the recipient names and checks for national team.
Dim Recipients As Outlook.Recipients
Dim recip As string
Dim i
Set Recipients = Item.Recipients
For i = Recipients.Count To 1 Step -1
Set recip = Recipients.Item(i) & ";" & recip
If InStr(LCase(recip), "national team") Then
Set Recipients = Nothing
Exit Sub
End If
Bill Inra says
Wow - I'm impressed that you continue to offer responses to this code. And I appreciate the original code and the updates.
I'm wondering if I'm the only one experiencing this - otherwise I'm surprised it's not already mentioned.
This VBA code only seems to work in my case on new emails. On replies, the bcc doesn't happen. Is that expected? If so, is there a way to make the bcc happen on all outgoing messages (not just new messages?).
Thank you.
Bill
Diane Poremsky says
it should go on every message, new or reply as it's done as the message is sent. Is the address Bcc'd not getting it? Is the BCC address not on the message in the sent folder?
Is a google/gmail server involved? Google hides messages it thinks are duplicated.
An overzealous antispam filter could also affect it, but I'd expect some to get through, just not all.
Rob says
Hi Diane,
I'm using Outlook 2016 , my email domain is not a Gmail or Yahoo domain or anything of the sort and am having the same problem with Reply's and Forward's. I checked to see if it was the Junk Filter, but even when turned off, the BCC doesn't work.
Any idea why I'm not getting the BCC message on the Reply's and Forward's?
Thank you for your help!
Rob
Shrikrushna says
thank you so much
Chris says
Hi Diane,
I think I posted my original comment in the wrong place, sorry for the duplication if so!
I copied and pasted the code to automatically BCC all emails sent through Outlook into VBA and works great! However I would like to put in the following conditions:
1. BCC all emails except for emails to john@xys.com
2. BCC all emails except for emails to anyone at @domain.com
Is this possible? If so, could you please tell me where I go to do this and what the code would be?
Thanks so much in advance!
Diane Poremsky says
you'll need to use an if statement. will john be the only address on the message? if so, you can use a simple if statements if instr(item.to, "john@domain.com") or instr(item.to, "domain2.com") then
exit sub
else
'do whatever
end if
if john or the domain could be on the to or cc line, you need to check the recipient collection:
Dim Recipients As Outlook.Recipients
Dim recip As Outlook.Recipient
Dim i
On Error Resume Next
' use lower case for the address
' LCase converts all addresses in the To field to lower case
Set Recipients = Item.Recipients
For i = Recipients.Count To 1 Step -1
Set recip = Recipients.Item(i)
If InStr(LCase(recip), "john@domain.com") or InStr(LCase(recip), "domain2.com") Then
' rest of macro
Josh says
Hi Diane,
somehow i am not sure where to paste the additional code in the rest of the macro. I want to bbc all outgoing emails, except if domainx.com is in To or CC. Would you please be so kind a let me know the WHOLE example code? Many Thanks for all your help: i looked everywhere also for other outlook tricks and slipstick.com is by far where i've found most answers.
Regards
Josh
Diane Poremsky says
this should work -
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
Set Recipients = Item.Recipients
For i = Recipients.Count To 1 Step -1
Set recip = Recipients.Item(i) & "," & recip
Next i
If InStr(LCase(recip), "domainx.com") Then
Exit Sub
End if
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Josh says
Hi Diane,
Many Thanks, but there is an item missing:
strBcc = "SomeEmailAddress@domain.com"
where does it go? I tried several places but it didn't work.
Regards
Josh
Diane Poremsky says
it can go right after 'on error resume next' - or anywhere before the line where it is added to the message.
Josh says
I believe I correctly followed your instructions but it stll BCC's emails to domain.com.
Here the code I am using:
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
strBcc = "SomeEmailAddress@domain.com"
Set Recipients = Item.Recipients
For i = Recipients.Count To 1 Step -1
Set recip = Recipients.Item(i) & "," & recip
Next i
If InStr(LCase(recip), "domainx.com") Then
Exit Sub
End if
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Diane Poremsky says
Try using If InStr(1, LCase(recip), "domainx.com") > 0 Then
Renda77 says
Hello, help me, i have the same problem :(
Does not filter a banned domain "domain123.com". Sends bcc email :(
Example:
send email to abc@abc.com (send bcc email: 123@123.com) OK
send email to abc@domain123.com (send bcc email: 123@123.com !!! BAD )
@domain123.com block code: " If InStr(1, LCase(recip), "domain123.com") > 0 Then "
Outlook 2016. Sorry my bad english. Thank you :)
My code is:
Diane Poremsky says
I don't see any issues offhand with the code. domain123.com won't match 123.com so that should not be an issue.
Christopher says
Hi Diane:
I have several email groups/distribution groups that I never want to have in the "To..." field when someone sends out an email. Is it possible to automatically move those to the "Bcc..." field (removing from the "To..." field) when clicking on send prior to actual delivery? So, if I send an email to CompanyEveryone that when it does send out the "To..." field is blank and the group CompanyEveryone defaults into the "Bcc..." field?
The goal is that when the email is received and aperson attempts to click on the "Reply" or "Reply to All" that those groups are not in the "To..." or the "Cc..." field. I don't want people to reply email to the specific email groups.
Diane Poremsky says
you can use an item send macro to check for dl names and move them to the BCC field. You'd do something like the macro in https://www.slipstick.com/how-to-outlook/prevent-sending-messages-to-wrong-email-address/ but instead of asking if you want to send, you'd set the address as a BCC.
John says
I'm trying to integrate our outgoing e-mail into Trello by having Outlook copy the outgoing mail to a specific board in out organization (achieved by having a rule for copying the mail to a job specific board based on a job identifier text string in the subject or e-mail body). If what I'm reading above is correct, the only way I could get this as a BCC and a standard CC (which is covered in the rules) would be to purchase Compliance Copies Add-In. Does that seem correct to you guys?
Diane Poremsky says
Yes, it looks like that should handle it. (I thought I replied to this a few days ago... sorry. )
tryke says
hi diane,
any idea on what to do if I want to know if I already reply on the email or not.
the setup is like this.
I have a Samsung tabet 10.1 and a laptop on the office, I used the tablet when im out side the office but the problem is sometimes I cant remember if I already reply on the email or not when I used my laptop so what happened is I always ending up reply twice to one email. one from my tab and one from my laptop.
Diane Poremsky says
What type of email account is configured on each? If you use IMAP or Exchange server, the changes should sync between the machines. You'll see which messages were read and the reply icon should display and if the icons aren't syncing, you'll be able to check the Sent Items folder.
ts says
Hi Diane, I resolved this and it works...
ts says
I resolved to send email to two recipients - now every email sent from outlook is sent also to BCC emails. But is it possible to deactivate this autoBCC sending for specific email? For example I want o send an private email to my wife and I don't want to BCC it? Is it possible to cancel the autoBCC by entering something to the BCC field or somewhere else (except deleting the script)? Thanks!
Diane Poremsky says
Yes, you need to add an if statement - something like this
if instr(1, item.recipients, "wife@address.com") then
exit sub
else
'the bcc code
'end if
Bruno says
Hi, ts
on the December 17, 2013 you wrote "I resolved to send email to two recipients - now every email sent from outlook is sent also to BCC emails".
How do you resolved it
In fact when I added strBcc = "address@domain.com;address2@domain.com;" outllok always screamed "Could not resolve the Bcc recipeint. Do you want to send the message?"
Thanks
ts says
Hi Diane, thanks for above scripts. I used the first version which worked for one recipient perfectly. When I added strBcc = "address@domain.com;address2@domain.com;" outllok screamed "Could not resolve the Bcc recipeint. Do you want to send the message?" and throwed the email into To: field. Email was sent but not delivered and I received a email message thet my email couldn't reach the entered recipietns. Am I doing something wrong (I am not a programmer)? Thanks!
sami says
Hello dear,
this is for one account. how can i use multiple account as BCC recipient ??
Diane Poremsky says
BCC to two addresses?
strBcc = "address@domain.com;address2@domain.com;"
Jodi says
I had to find a different path to automatically BCC myself. I tried the VBC code but couldn’t get it working again after the first day.
The solution I came up with was creating a rule in Outlook that applied to all email I sent, it would ‘move a copy to a specific folder’, and I created no exceptions. I named it BCC so I’d remember what the rule does.
Diane Poremsky says
The usual cause of the code not working in macro security settings. But, if a built in tool does what you need, you should use it over VBA.
bpiereder says
I added the Dims you've got at the end of the Dim list at the top and added:
strAccount = "Billing"
strAccount = "Customer Service"
strAccount = "Tech Support"
For Each oAccount In Application.Session.Accounts
If oAccount.DisplayName = strAccount Then
This is what I've got right before the End Sub (in separate lines but comment box will only expand so far):
Else End If Next End If End If Set objRecip = Nothing
Diane Poremsky says
It expands - it just tries to make you think it doesn't. :) If you press enter, it keeps scrolling and tab brings up the buttons.
Are those strAccounts the ones you want to use? If you need to block more than one account, you'll use a case statement.
In any event, everything is being BCC in my tests tonight.
bpiereder says
using 2007
Question:
is there a way to only BCC an address when the specified four of the five available accounts (not the 'from' field but the Account drop down below the send button) is used?
Diane Poremsky says
When you send on AccountA, Acctc, acctd, BCC, when you send using AcctB don't bcc? Sure.
You'd add something like this to the macro - i didn't test it, so it might need a little more tweaking.
Dim oAccount As Outlook.Account
Dim strAccount As String
Dim olNS As Outlook.NameSpace
Dim objMsg As MailItem
On Error Resume Next
strAccount = "account name"
For Each oAccount In Application.Session.Accounts
If oAccount.DisplayName <> strAccount Then
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
'yadda yadda yadda
'rest of macro
else
End If
Next
End If
End If
Set objRecip = Nothing
End Sub
Alane McKinnon says
Go into the Trust Center, Macro Settings. I believe the default is to Disable all macros without notification. Change it to Notifications for all macros. Then at least every time you open Outlook, you will have the option to enable macros. You could Enable all macros, but of course, that is not recommended. If you do not have this setting checked, then apparently as soon as you re-boot your computer and start up Outlook, the macro won't work anymore. This will solve that problem.
karl says
I have the same problem even though i have change the macro security to low (enable all macros). I am using Outlook 2010 with Win7
Any advise?
Diane Poremsky says
Do you get any error messages?
R Clark says
Hello. I followed your instructions to bcc all my Outlook emails to my gmail account and it has worked a dream. THANK YOU!!! Very simple instructions which worked perfectly. I am very grateful.
Bill Craven says
DUH! I closed Outlook, waited a minute, and opened Outlook again. Auto BCC works great! Thanks
Bill Craven says
Help! I copied and pasted the automatic BCC code and did a SAVE. When I try to RUN a popup asks for Macro Name? Do I need to do anything other than save the macro and change the security?
Becky says
I used the code referenced above and it worked great...until I closed out Microsoft Outlook. It asked if I wanted to save the project...I said yes. The code is still in place when I go back into it, but it no longer BCCs the e-mail I put in place...any thoughts?
Diane Poremsky says
Do you have Macro security set to low?
David Jordan says
Is there vb code to not bcc if sent to a domain, or possibly a certain email address?
Diane Poremsky says
I think I've started this reply 4 times now, only to have firefox crash on me. :(
You need to use an if.. then statement - something like this:
If InStr(LCase(Item.To), "diane@somewhere.com") Then
End
Else
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address
' or resolvable to a name in the address book
strBcc = "granny@mobilegranny.com"
A final end if needs added at the end...
David Jordan says
Thanks for your reply! We are using exchange online. How would you go about doing that?
Diane Poremsky says
Sorry, I just checked and To and CC fields are covered in Transport rules but not Bcc field.
David Jordan says
Is there a way to exclude an entire domain from being BCC'd? I would like to be able to exclude our companies domain so that internal emails will not be BCC'd. We have 3 domains we would like to exclude.
Thanks,
David
Diane Poremsky says
Which version of Exchange do you use? If you are using Exchange server, you should be able to filter it at the server level.
Alex says
I am not sure if my syntax is correct. I have very little experience with programming, and this was with C++ years ago. This is what I have, but it doesn't seem to be working. Any adivce?
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim res As Integer
Dim strBcc As String
On Error Resume Next
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address or resolvable
' to a name in the address book
If Item.To = "jane@123law.com" Then
strBcc = "joe@123law.com"
End If
Set objRecip = Item.Recipients.Add(strBcc)
objRecip.Type = olBCC
If Not objRecip.Resolve Then
strMsg = "Could not resolve the Bcc recipient. " & _
"Do you want still to send the message?"
res = MsgBox(strMsg, vbYesNo + vbDefaultButton1, _
"Could Not Resolve Bcc Recipient")
If res = vbNo Then
Cancel = True
End If
End If
Set objRecip = Nothing
End Sub
Thank you.
Diane Poremsky says
Instead of
If Item.To = "jane@123law.com" Then
strBcc = "joe@123law.com"
End If
Set objRecip = Item.Recipients.Add(strBcc)
End If
End If
put the item.to end if at the bottom - you only want to bcc if the address matches.
If Item.To = "jane@123law.com" Then
strBcc = "joe@123law.com"
Set objRecip = Item.Recipients.Add(strBcc)
End If
End If
End If
Alex says
Is there a way to modify the code to BCC someone on e-mails sent to a specified person?
Diane Poremsky says
Yes. Use an if statement to test the address "if item.to = "alias@domain.com" then ... end if
Steve G says
I am a newbie here - so pls forgive my ignorance. Why is this not already a feature of Outlook?
thanks
Diane Poremsky says
I have no idea why Microsoft never added it as a feature. Sorry.
Greg says
Yea. Idk why not. I suck at vbscript. I guess you need a foreach statement to parse the ;'s. I was using Outlook 2007 btw.
Diane Poremsky says
I'm just getting back into VB after a non-complete clause ended (and too much other stuff going on to keep my vba skills up during the period) and am a little rusty in some areas too. I didn't get a chance to look at it last night, I'm going to try to do that today... or I'll just ask one of my developer friends about it.
Greg says
Actually after some playing around I figured it out. Here it is for anyone else who might ask the same thing! :)
Private Sub Application_ItemSend(ByVal Item As Object, _
Cancel As Boolean)
Dim objRecip As Recipient
Dim strMsg As String
Dim strCcc As String
Dim res As Integer
Dim strDcc As String
On Error Resume Next
' #### USER OPTIONS ####
' address for Bcc -- must be SMTP address
' or resolvable to a name in the address book
strDcc = "Employee ONE"
strCcc = "Employee TWO"
Set objRecip = Item.Recipients.Add(strDcc)
objRecip.Type = olBCC
objRecip.Resolve
Set objRecip = Item.Recipients.Add(strCcc)
objRecip.Type = olBCC
objRecip.Resolve
Set objRecip = Nothing
End Sub
Thanks man!
Greg says
How can I go about making it so I can bcc email to two people at the same time?
I tried: strBcc = "address1@domain.com; address2@domain.com" and your warning dialog came up, so I removed the if portion of the code and tried it and the email sent out but I got a return back saying: Your message did not reach some or all of the intended recipients. The following recipient(s) cannot be reached: and it is blank after that.
Ideas? Thanks for the free vb script!
Diane Poremsky says
That string with the semicolon delimited addresses should have worked but I'm glad you figured out how to make it work.
SysAdm says
Thanks for all of the advice here, Diane and others... I do agree that this "should be" as simple as a rule, and I don't know why it isn't.
* BTW, you show "CTRL + P" for the pasting option... I'm sure it was a typo, and you know it's "CTRL + V", but I thought you may want to update it anyway.
Thanks again
Diane Poremsky says
Thanks for picking up that typo - yes, I meant Ctrl+V (and use it all the time).
Gregory J Schimoler says
I cannot believe there have been no posts since Mar2012. I have a PhD in CompSci - your VBA code is nonsense.
Does MS filter these posts - to eliminate anything too critical of MS?
MS has been promising a 3rd party freeware plugin link for years - where is it? Which of the list you show are free? I have been a loyal business Microsoftt customer since the first PC (I did in fact order the first IBM PC for PepsiCo in the early 80's!) Used 07 and Bberry for many years.
So what are you telling me? I should use gmai as my primary and bcc outlook?
A reply throught the message board and direct to my private email would be most appreciated.
Greg Schimoler (see my LinkedIn)
President & CEO
GJS Consulting
Diane Poremsky says
No Microsoft filters on this site - as long as comments are not vulgar and get past the spam filter, they get approved. I'm not aware of promises of free plugins offers from Microsoft.
To the best of my knowledge, none of the BCC add-ins available are free - the VBA code sample is free and works great but is very basic - the add ins have more features.
Diane Poremsky says
On Michael's question about BCC incoming messages, a run a script rule would do it. I'd use the autoaccept rule as the basis for one for copied the necessary fields into a new message.
(Not sure where my brain was in March... it wasn't in working mode as this would take, oh maybe 10 minutes to cobble together. )
Here is a working rule to forward meeting request and cancellation details to another address. It took a little longer than 10 minutes but I got sidetracked more than once.
Forward meeting details to another address
Michael says
How about simply BCC only the incoming or generated meetings and appointments, not regular emails?
Michael says
I would like to automatically BCC incoming or generated (meeting, appointments) requests and cancellations to my gmail account from within outlook 2010. but I only want to have the subject, time and location - not the body or other recipients of the request.
Is this possible?
Thanks,
Michael
Diane Poremsky says
It's more complicated - you'd need to create a new message and copy that info from the original.
Normal User says
Most of your answers on different forums try to prove to people requesting help with automatic BCC that they either don't need that, or they are enough professional to write VBA code.
Try to listen to the people. This feature is needed in Outlook, and your VBA code don't always work. For example if you use BlacBerry device associated to the mail account.
Diane Poremsky says
How would Outlook automatically doing BCC help with a BlackBerry device? It would only work in Outlook, just as the supplied VBA code (and the addins) work fine only within Outlook - when a BB sends mail, it bypasses Outlook and goes straight to the outgoing server. To send BCC from other devices, you need a solution on those devices or on the server - which Exchange's Transport Rules can do. With a transport rule (configured by the administrator), you can BCC mail based on one of more conditions - such as all mail from a person or group, all mail sent to a domain etc. Because this is done at the transport level, it should get all mail sent using EAS or BES.
Diane Poremsky says
BTW, RE Blackberry: if you have BIS email accounts you can configure auto BCC in the web interface (probably on the handset too) and BES accounts can be configured to auto bcc. For BIS, go to https://carrier.blackberry.com/ (replace carrier with your cell provider, verizon is vzw, not sure about the others) and double click on the email account - the auto bcc field is only visible after the account is added, not before.